- Topics - 3
- Replies - 13
- Total Posts - 16
You can also see the online MorenaStudio web scanning example from Gnome company:
You can find the Java source code with the upload (save too) solution in the MorenaStudio.java file located in the examples directory of the distribution package. You can download the distribution package here:
Morena Framework is a commercial product, but it is free of charge for educational and personal home usage.
To the PDF:
Morena Framework delivers scanned data via standard Java ImageProducer interface. So the task is: “How to save acquired data to the PDF file format, if the they are produced via ImageProducer interface?” We have a feedback from our customers, that they have good experiences with iText, a free library for generating PDF files.
Here is a snapshot demonstrating how to save to pdf file using iText library:
TwainSource source = TwainManager.selectSource(null);
MorenaImage morenaImage = new MorenaImage(source);
com.lowagie.text.Image iTextImage=com.lowagie.text.Image.getInstance(image, null);
Document document=new Document(iTextImage);
PdfWriter writer=PdfWriter.getInstance(document, tmp);
But, you can use your preferable PDF libraries.
Member of Gnome’s technical support[/code]