Free Support Forum - aspose.com

PDF to TIFF issue - TiffSettings ignored without Resolution

I have written a very simple program to convert a color PDF to a TIFF with Group-4 compression. I have discovered that when I create the TiffDevice, the TiffSettings are ignored unless I also include a Resolution object.


This way I incorrectly end up with a color tiff and LZW compression
TiffSettings tiffSettings = new TiffSettings();
tiffSettings.setCompression(CompressionType.CCITT4);
tiffSettings.setDepth(ColorDepth.Format1bpp);
TiffDevice tiffDevice = new TiffDevice(tiffSettings);
tiffDevice.process(pdfDocument, tiffStream);

This way I correctly end up with a B&W tiff and Group-4 compression.
Resolution tiffResolution = new Resolution(300);
TiffSettings tiffSettings = new TiffSettings();
tiffSettings.setCompression(CompressionType.CCITT4);
tiffSettings.setDepth(ColorDepth.Format1bpp);
TiffDevice tiffDevice = new TiffDevice(tiffResolution, tiffSettings);
tiffDevice.process(pdfDocument, tiffStream);

Hi Ron,

Thanks for your inquiry. I have tested the scenario using Aspose.Pdf for Java 10.0.0 and managed to observe the reported issue. For further investigation, I have logged an issue in our issue tracking system as PDFNEWJAVA-34739 and also linked your request to it. We will keep you update via this thread regarding the issue status.

Please feel free to contact us for any further assistance.

Best Regards

The issues you have found earlier (filed as PDFNEWJAVA-34739) have been fixed in Aspose.Pdf for Java 10.4.0.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.