Tiff to Pdf conversion missing colored pages after conversion


Hi there,
In the project I am working on I am converting tiff files to pdf using aspose-imaging-3.6. The tiff file contains both blackwhite and colorful pages(41 pages). After conversion the colorful pages are missing in the resulting pdf(33 pages). Here is the code snippet I use for conversion:

	Document doc = new Document();
	float marginInCm = 0.0f;
	Page page = doc.getPages().add();
		try(FileInputStream fis = new FileInputStream(file)){
			Image image1 = new Image();
			doc.save(result.getPdfResultFile().getAbsolutePath(), SaveFormat.Pdf);

With this code I can convert bmp, jpeg files to pdf. I can also convert tif to pdf if the tif file does not contain colored page or contains only colored pages.



I like to inform that you are using very old version of Aspose.Imaging. Can you please try to use Aspose.Imaging latest version on your end and if there is still an issue than please share source files along generated result so that we may further investigate to help you out.


Thanks for your quick response. I upgraded aspose-imaging to 18.11 and the problem remains. It seems that aspose library recognizes the file as black and white. I created temporary file using:

TiffOptions options = new TiffOptions(TiffExpectedFormat.TiffJpegRgb);
image = com.aspose.imaging.Image.load(file.getAbsolutePath());
image.save(tmpImageFile.getAbsolutePath(), options);

Then, converted that file and the result was as expected.

Is it possible to load the file with TiffLoadOptions and expected format as rgb?



I have observed your comments and request you to please share the source and generated output file for comparison on our end.