Question: how are bmp files stored?
Answer: Pixel storage. The bits representing the bitmap pixels are packed in rows. The size of each row is rounded up to a multiple of 4 bytes (a 32-bit DWORD) by padding. For images with height above 1, multiple padded rows are stored consecutively, forming a Pixel Array.