问题
I'm working on building an app to scan directly from TWAIN scanner to a Java applet. I'm already aware of Morena and JTwain, but they cost money. I need free. I could re-invent the wheel with JNI, but it seems like someone has probably already done this as a FOSS tool.
Is anyone familiar with a free tool that can get a Java applet to read directly from a TWAIN scanner?
回答1:
Calling the TWAIN API from anything except C/C++ is going to be a major pain, it relies entirely on complicated C structures that you have to replicate exactly in memory. If you need only fairly basic scanning, you could use something like GitHub site to call my old free 'EZTwain Classic' DLL (google for eztw32.dll)
回答2:
hm. I might have some homebrew available for it somewhere I could check, but for now: At our company, we basically gave up on this issue and implemented an (unfortunately win only) ActiveX solution: Site Link
回答3:
I've actually purchased the chestysoft activeX control. Been using it for about 3 years. Works great but as with all ActiveX you are restricted to IE. And this one is 32-bit only. I'm looking into a flash approach now. Since flash can capture from a camera why not from a scanner. If I remember I'll report back what I find.
来源:https://stackoverflow.com/questions/11338/getting-java-and-twain-to-play-together-nicely