pdf-redact-tools icon indicating copy to clipboard operation
pdf-redact-tools copied to clipboard

Added flag for quality

Open anaisabel7 opened this issue 7 years ago • 3 comments

A command line option to set the quality sent to the 'convert' program on exploding has been set. The value given to quality must be an integer, but no other limitations where implemented.

Tests were not written since no unittest structure could be found in the project.

This PR should deal with issue #13

anaisabel7 avatar Jun 08 '17 10:06 anaisabel7

Sorry, a previous PR caused some conflicts with this one. It's simple enough though and I resolved them, but I confirmed that this didn't actually fix the problem. I took a PDF and tried exploding it with quality 10, and then tried exploding it again with quality 100, but in either case it outputs identical PNGs.

I think that maybe -quality just doesn't do what we thought it did in this context.

micahflee avatar Jun 20 '17 00:06 micahflee

@micahflee Thank you for checking this :smiley_cat:

anaisabel7 avatar Jun 20 '17 16:06 anaisabel7

Since PNG is a lossless format, the quality option to convert doesn’t actually reduce or improve visual quality, it just controls (losless) compression with Deflate/zlib:

Instead, the density or resolution in DPI may be increased.

ocram avatar Dec 15 '19 19:12 ocram