mirror of
https://github.com/storytold/pdfcraft.git
synced 2026-11-01 14:08:23 -06:00
Export ▸ Images and Save Image As decoded an image with Stream::decoded, which reads /DecodeParms only when it is direct. An image whose PNG predictor came by reference (the dictionary, an entry of an array, or the numbers inside) kept its row tags in the samples, and the picture came out shifted. The same was true of an indexed image's lookup table given as a stream, and of a JBIG2 image's /JBIG2Globals stream, which then couldn't be read, so the image was skipped. All three now decode through Document::with_direct_parms (#4304), as the optimizer does, and a test exports each. Found by CodeRabbit on #4805; the image decode was already this way on main. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01P6yUtvWGPsJpMLyh6pxSXG