PNG
PNG is a lossless raster-image file format supporting indexed, grayscale, and truecolor images, with optional transparency and metadata.
Learn Go with Pocket-Sized Projects
PNG is a lossless raster image file format that supports indexed, grayscale, and truecolor images with optional transparency.
- How it is used
- Preserves exact pixel colors when raster data represents maze walls, paths, entrances, and treasures.
- How deep it goes
- Explains raster pixels, RGBA access, decoding, encoding, and scan order without detailing PNG compression internals.
- Examples
- Uses a PNG RGBA maze whose explored path is highlighted in a second image.
- What you can do after
- Build a Go tool that decodes, inspects, modifies, and encodes PNG images through standard image packages.
Web Design Playground, Second Edition
PNG is a lossless raster image format that supports indexed, grayscale, and truecolor images, including alpha transparency.
- How it is used
- Deploys PNG for web illustrations, logos, and icons that use solid colors or transparency.
- How deep it goes
- Explains PNG use, color-depth choices, and optimization, but stops short of describing encoding internals.
- Examples
- Uses an atomic-logo.png example, simple logos and icons, 8-bit color, 24-bit palettes, and PNG optimization tools.
- What you can do after
- Apply it via PNG color-depth choices, image optimization tools, and the HTML img element.
Read how Web Design Playground, Second Edition explains PNG →
Related concepts
- JPEGalternative to · JPEG is a raster-image compression and file-format standard commonly using lossy compression for photographs and other continuous-tone images.
- JuicyPixelsused by · JuicyPixels is a Haskell library for decoding, encoding, and manipulating common raster image formats.
- mazeused by · A maze is a spatial puzzle or problem space of connected and obstructed routes in which a path must be found between designated locations.
- RGBA coloruses · An RGBA color is a color representation specifying red, green, blue, and alpha channel values.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.

