Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Higher compression for PDF's #7

Open
user8446 opened this issue Mar 20, 2023 · 1 comment
Open

[Feature Request] Higher compression for PDF's #7

user8446 opened this issue Mar 20, 2023 · 1 comment

Comments

@user8446
Copy link

user8446 commented Mar 20, 2023

Hi,

Since the main focus is scanning receipts, it would be better to have higher compression for the PDF's. A simple 8.5x11 paper is averaging in the 300k range. This is more data send over a mobile device and also more storage. Multiplied over many uploads over time this really has an effect.

Thank you

@sandreas
Copy link

sandreas commented Sep 12, 2024

+1

I was pretty successful using PNG with 1bit color palette + dithering to store images in the PDF in one of my projects. The PDFs got insanely small.

You could also go up to 8bit, if you need more nuances.

Here is a StackOverflow article on how to do this in Java:
https://stackoverflow.com/questions/65953579/how-to-implement-1-bit-dithering-using-java

And here is a PNG Library that might be useful:
https://github.com/nayuki/PNG-library

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants