Access Image Kit framework from Java code

Discussion in 'Mac Programming' started by moonman239, Jun 21, 2015.

  1. moonman239 macrumors 68000

    Mar 27, 2009

    I'm building a Java application and would like to enable the end user to scan in an image from his/her document scanner. For Mac OS X, I'll use Image Kit.

    The problem is, the framework is written in Objective-C. While I know how to program in Objective-C, I'd much rather use Java as much as possible.
  2. Madd the Sane macrumors 6502a

    Madd the Sane

    Nov 8, 2010
    There used to be a way to write Cocoa code in Java, but that was removed in 10.5. You could use JIGS (Java in GNUStep), but that'd probably be overkill if you are trying to access one API.

    I'm afraid the only way to do this would be to create a bridge that uses C functions to bridge back to Java. You'll probably have less headaches if you disable ARC and use manual reference counting.
  3. hokan macrumors member

    Mar 18, 2014

Share This Page