Op 7/06/2012 15:11, Jason Berk schreef:
> Any suggestions?
Yes, there's an example on how to downsize images in the book on p528.
You can find the corresponding code here: http://1t3xt.be/?179

Note that this example uses 'brute force' to find images.
You may want to adapt the code to find the images through the XObjects 
in the Resources of page dictionaries and XObject dictionaries.

Basically, you give a PDF stream to iText's PdfImageObject class, and 
this class will return an instance of Java's BufferedImage.
Changing the resolution of the image is done using methods available in 
the Java SDK.
Then you can write the image to an array of bytes (in the example: 
encoded as JPG).

These bytes can be used to alter the image stream (as JPG images are 
stored AS-IS inside PDF, this isn't the case with some other image formats).

Note that you're a paying customer, so you can also use the closed mail 
address if you have further questions.

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

iText(R) is a registered trademark of 1T3XT BVBA.
Many questions posted to this list can (and will) be answered with a reference 
to the iText book: http://www.itextpdf.com/book/
Please check the keywords list before you ask for examples: 
http://itextpdf.com/themes/keywords.php

Reply via email to