Like JPEG, PNG can carry a color profile that tells viewers exactly which "red" pixel value 255,0,0 represents. Unlike JPEG, PNG offers four different mechanisms: an embedded ICC profile, a "this i…
PNG defines five color types in IHDR. Each one maps onto a different PDF color space and has different file-size implications. Picking the right type before saving a PNG can shrink the file by 50–8…
PNG's compression is deflate (the zlib/gzip algorithm) applied to a row-by-row pre-processed stream. The pre-processing — five "filter" types that turn pixel bytes into residuals against neighborin…
PNG optimizers are a small ecosystem of tools that reduce PNG file sizes without changing pixel data. They work by trying alternative encoding strategies for the same pixels and picking the smalles…
PNG and PDF share a remarkable property: both use deflate (zlib) for lossless compression of pixel data. PDF's /FlateDecode filter is deflate. With one extra parameter — a row predictor — PDF can i…
Screenshots are different from photos in ways that matter for PDF embedding. Photos have continuous tones, soft edges, mild noise — JPEG-friendly content. Screenshots have sharp edges, flat colors,…
PNG's killer feature for screenshots and graphics is its alpha channel — per-pixel transparency that lets logos sit cleanly over any background. PDF supports the same concept but stores it differen…
The choice between PNG and JPEG predates PDF embedding by 25 years, but the consequence shows up in PDF size. A 5 MB JPEG becomes a 5 MB PDF; a 50 MB PNG of the same content becomes a 50 MB PDF. Pi…