Skip to content
Matthias Görges edited this page May 29, 2014 · 1 revision

png-stride returns the stride (bytes per pixel) of a PNG file. The options are 1 for a sole alpha channel, 3 for RGB color space, and 4 for RGBA color space.

Parameter Description
fname PNG file to obtain information from

Example

Example 1: Return image information of the panda-icon.png from uSquish.

> (define fname (string-append (system-directory) (system-pathseparator) "panda-icon.png"))
> (png-width fname)
64
> (png-height fname)
64
> (png-depth fname)
8
> (png-stride fname)
4
Clone this wiki locally