After messing with Antti's Character Set Viewer (
http://www.lucasforums.com/showthread.php?s=&threadid=82789) I decided to knock up a quick version of my own. (
http://quick.mixnmojo.com/charset.gif)
The specs as set out in various places are:
4 bytes Header
4 bytes BE Size
6 bytes Unknown
15 bytes Colour Map
1 byte Bits per pixel
1 byte Max char height?
1 byte No chars
1 byte Unknown
4 bytes * NoChars Character Offsets
if NoChars=0 then NoChars=256
Character Offsets are relative to the end of the Colour Map data (byte 29)
Individual char data:
1 byte Char width
1 byte Char height
1 byte X offset
1 byte Y offset
x bits Data bitstream
Thats all fine, but I dont know how to choose the correct colours for the character data. At 1bpp theres 2 possible colours, at 2bpp 4 and at 4bpp 16.
I can guess at colour values of course, but I'm unsure as to how the colour values are obtained or how they relate to the colour map. I've got a nasty suspicion that the colours are set in the game scripts and that they specify what colour values go into the colourmap but of course I dont really know.
If anyone could explain this to me, or work out the answer from the scummvm source it'd be much appreciated :)
Oh, I'm also unsure what bits map to which colour in the colourmap at 4bpp. I've looked at the ScummVM source for all this, but being ignorant of C++ I couldnt figure it out..