Access scanner from Java or Python (or something else if it's technically motivated) in Linux (but Windows would be nice)
I want to write a system for handling important documents in my home. This is the user story for getting a new document:
- I "Add new document" and am prompted to scan it using my combined printer/scanner.
- I view the scanned copy to see it's of good enough quality. Which it has.
- The system tells me to mark it with number N, which I do. I also enter title, document type, description and when the document is no longer needed to be stored (could be never to always keep it).
The problem is accessing the scanner. I do not know what the smoothest way is. Ideally it would support "all" scanners through some kind of standard interface. I do not know if that even exists. Should I do this in Java, Python or something else?
My primary platform is Linux. But if it worked on Windows too, that would be nice. If I开发者_JS百科 manage to create something useful I'll release it as GPL, so it's for a good cause too. ;-)
Thank you for reading!
Under Linux, the common interface to scanners is SANE.
The standard interface for scanners is TWAIN. If you google for "java twain" or "python twain", you get plenty of useful-looking stuff, e.g.
- http://www.programmersheaven.com/2/Java-Twain-image-acquisition
- http://twainmodule.sourceforge.net/
精彩评论