The IBM-PC also had it's own BSAVE image format. The following links desbribe this format and provide image examples. I also selected some of the examples and attached them here.
For the .PIX r, I think that the color depth can be calculated by comparing the dimensions informed at the offsets +7 and +9 agaisnt the number of bytes obtained from the rest of the header.
The last problem that remains is to differentiate between the CGA 4-color or monochrome modes on a .PIC file. I really see no way other than manual selection. Same deal to select which of the palettes will be used on the CGA 4-color mode.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
How can I tell if the header is 7 or 11 bytes?
How do I determine the graphics mode?
That's a really hard question. According to wikipedia, the graphics mode was differentiaded by the extension:
.PIX = 11 bytes header
.BSV = CGA text mode
.PIC = CGA graphics mode with 7 bytes header
.CGX = XCGA
.BLD+.PLT = MCGA
For the .PIX r, I think that the color depth can be calculated by comparing the dimensions informed at the offsets +7 and +9 agaisnt the number of bytes obtained from the rest of the header.
The last problem that remains is to differentiate between the CGA 4-color or monochrome modes on a .PIC file. I really see no way other than manual selection. Same deal to select which of the palettes will be used on the CGA 4-color mode.