![]() |
tinyimg 1.0.0
Lightweight image manipulation library for Cloudflare Workers
|
Windows bitmap codec. More...
#include "tinyimg/codec/codec.h"Go to the source code of this file.
Variables | |
| const TinyCodec | tiny_codec_bmp |
| The BMP codec. | |
Windows bitmap codec.
|
extern |
The BMP codec.
Decodes 1, 4 and 8 bit palettes, 16 bit packed, 24 bit BGR and 32 bit BGRA, uncompressed or RLE8, in either row order. Encodes 8 bit grayscale, 24 bit BGR, or 32 bit BGRA behind a V4 header when the image carries alpha.
A 32 bit BI_RGB file with only the 40 byte header is read as opaque, because the fourth byte is padding in that layout and reading it as alpha turns a normal image transparent. Alpha is honored when a mask says it is there.
Region and scaled decode read only the rows and columns they need. RLE8 is sequential, so a region of an RLE8 file expands the index plane first.