James R. Barlow
f5d308a156
optimize: refactor tricky /Filter and /DecodeParms handling
2018-04-18 15:30:21 -07:00
James R. Barlow
3869996758
optimize: jbig2 error
2018-04-18 01:36:38 -07:00
James R. Barlow
cdb2107c4e
optimize: jbigs2 fix
2018-04-18 01:31:35 -07:00
James R. Barlow
4db2b3413b
optimize: more robustness
2018-04-18 01:25:34 -07:00
James R. Barlow
b2f31bec79
Make optimize a lot safer
2018-04-18 00:20:06 -07:00
James R. Barlow
78f9f4a266
Be more defensive about accessing
2018-04-18 00:11:39 -07:00
James R. Barlow
ad6087c342
optimize: more fixes
2018-04-17 23:58:10 -07:00
James R. Barlow
0d6ef430de
optimize: fix "length not defined"
2018-04-17 23:38:00 -07:00
James R. Barlow
a5942209e8
optimize: fix error on missing /Filter
2018-04-17 23:27:56 -07:00
James R. Barlow
9a60694cfc
optimize: ccitt header fixes
...
Changed to match TIFF spec's use of unsigned types, eliminated check for
/Columns.
There is some complex behavior for /Width != /Columns and
(/Width, /Columns) mod 8 != 0
that is not described well in the PDF spec.
2018-04-17 23:27:25 -07:00
James R. Barlow
4bf13f4737
optimize: be less chatty
2018-04-17 23:25:41 -07:00
James R. Barlow
c974aec934
Search for image masks too
2018-04-17 02:06:08 -07:00
James R. Barlow
3033f03f64
Iterate images with pikepdf / fix mono PNG corruption
...
To work around PNG corruption problem in PyMuPDF for monochrome images,
extract and save monochrome CCITT with synthetic TIFF header.
Works better but currently skips /ImageMask due to qpdf
implementation, which affects many files.
2018-04-17 01:50:37 -07:00
James R. Barlow
72723e0bb5
optimize: be quieter
2018-04-16 18:06:02 -07:00
James R. Barlow
2fb6ab3939
Trap writePNG error
2018-04-16 17:29:10 -07:00
James R. Barlow
25c1c160b8
Move optimize to new file
2018-04-16 17:22:06 -07:00