Flattened pixmap
Appearance
The flattened pixmap is a structure used to load and same images to and from disk.
Elements
A flattened pixmap is a cluster consisting of 6 elements:
- image type is reserved for a future use. It should be 0. It is a U16.
- image depth describes the bit depth of the colors in the image. It's value affects how the image and colors elements are interpreted. Valid values are: 1, 4, 8, 24, and 32. It is a U8.
- image is an one-dimensional array of U8s describing the color of each pixel. The meaning of this array changes depending on the value of image depth:
- For 1-, 4-, and 8-bit images m x n pixels in size, image is m*n elements long. Each pixel value contains an index into the colors array, which contains the actual color for the pixel.
- For 24-bit images m x n pixels in size, image is 3*m*n elements long.