I am extracting images/pages from a pdf file using PDFIUM. They are rendered to bitmap and I then save them to PNG.
Getting the maximum compression/file size is extremely important.
I have used a opensource product called PDFToPNG to carry out the same exercise.
It achieves precisely the same quality of png (same dimensions, same bitdepth) but at broadly 25% of the file size achieved by ImageEnIO.
I have looked at the suggestions in this topic:
https://www.imageen.com/ieforum/topic.asp?TOPIC_ID=2878
They don't help much.
I am currently extracting the bitmap from the PDF and then processing as follows:
ImageEnIO.LoadFromFileAuto(OpenDialog1.FileName);
ImageEnIO.params.PNG_Filter := ioPNG_FILTER_ALL;
ImageENIO.params.ResetInfo;
ImageEnIO.params.PNG_Compression := 9;
ImageEnIO.SaveToFilePng(FileName);
Do you have any idea what more I can do to achieve anything close to the file size achieved by PDFToPNG?