Halfive Bitmap Specification

Copyright Nomagno 2021-2023

Copying and distribution of this work, with or without modification, are permitted in any medium without royalty, provided the copyright notice and this notice are preserved. This work is offered as-is, without any warranty.

It is recommended to use the “.h5bmp” extension for H5BMP bitmaps (where applicable). H5BMP is identified by the MIME type application/x-h5bmp

H5BMP is a simple storage format for bitmaps


The H5BMP format:

It is identified by the null-terminated ASCII string ‘H5BMP\0’. These six bytes shall appear at the start of every bitmap. After the identifier string, two bytes shall follow and mark the bitmap height, and right after two bytes shall indicate the bitmap width. Following the height and width, (width times height) two-byte pixels follow, where each string of (width) pixels represents a row, starting from the top left of the image.

The pixel format (RGBA 5551) in binary:

RRRRR GGGGG BBBBB A