You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
During my process of compressing PDFs using PyMuPDF, I noticed that after converting images to JPEG, the original object's Filter is set to /DCTDecode. However, when I used other online tools to compress PDFs, I observed that they seem to employ two layers of compression: one with JPEG compression (setting the Quality to 60 in DecodeParms), and another with the FlateDecode filter. This approach seems to significantly reduce the PDF size.
I would like to know if it is possible to achieve this using PyMuPDF. If so, after setting the Filter entry for the object, what additional steps are required to handle the content stream properly?
Thank you for your assistance.
Best regards,
Syntamin
PyMuPDF version
1.24.7
Operating system
MacOS
Python version
3.11
The text was updated successfully, but these errors were encountered:
Description of the bug
About set PDF Filter
How to reproduce the bug
Hello,
During my process of compressing PDFs using PyMuPDF, I noticed that after converting images to JPEG, the original object's Filter is set to /DCTDecode. However, when I used other online tools to compress PDFs, I observed that they seem to employ two layers of compression: one with JPEG compression (setting the Quality to 60 in DecodeParms), and another with the FlateDecode filter. This approach seems to significantly reduce the PDF size.
I would like to know if it is possible to achieve this using PyMuPDF. If so, after setting the Filter entry for the object, what additional steps are required to handle the content stream properly?
Thank you for your assistance.
Best regards,
Syntamin
PyMuPDF version
1.24.7
Operating system
MacOS
Python version
3.11
The text was updated successfully, but these errors were encountered: