We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

BMP to PDF Conversion Mirrored and Upside-Down

Hi


I’m testing out Aspose conversion of BMP to PDF and have hit a problem with my 256 colout test file (attached). It produces the PDF attached. The colours, mirroring and orientation are all wrong.

This is my test code:

Pdf pdf = new Pdf();
Section sec = pdf.getSections().add();
Image img = new aspose.pdf.Image(sec);
sec.getParagraphs().add(img);
img.getImageInfo().setFile(“C:\example.bmp”);
pdf.save(“C:\example.pdf”);

Please can you advise on this.

Thanks, Richard


Version info:
com.aspose
aspose-pdf
11.2.0

Hi Richard,


Thanks for your inquiry. Please use new generator(com.aspose.pdf) for image to PDF conversion, it will resolve the issue. Please check following documentation link for the details.


Please feel free to contact us for any further assistance.

Best Regards,