General Questions - Subspace Banner Colortable 2dragons - Sun Jun 20, 2004 3:43 am Post subject: Subspace Banner Colortable
Rather than figure it out I thought I'd ask first:
When getting a banner in any part of SS, it is recieves it as 96 bytes, each byte representing a pixel of the bitmap.
How can I determine what color is represented by each byte value? What I know of bitmaps is that if they are <= 8 bits they include a colortable. However obviously that isn't the case here.
So if you know how it works that'd be great.
Bak - Sun Jun 20, 2004 4:26 am Post subject:
isn't that just a 256 color bitmap then? 1 byte each?
wEaViL - Sun Jun 20, 2004 5:06 am Post subject:
ss graphics are 8bit bmp's that includes banners and everything.
SuSE - Sun Jun 20, 2004 7:12 am Post subject:
wEaViL wrote:
ss graphics are 8bit bmp's that includes banners and everything.
no
Mr Ekted - Sun Jun 20, 2004 7:26 am Post subject:
Banners use the default SS palette, which is implied (not included) in the 96 bytes. If a given pixel has the value 12, then its color is palette entry 12. Open any of the default SS graphics files (or a banner file) in Photoshop and you can see the SS palette.
SuSE - Sun Jun 20, 2004 7:58 am Post subject:
while the game does seem to convert a banner to ss palette regardless of color depth settings - I can still have a 32-bit bmp banner in my folder and use it
CypherJF - Sun Jun 20, 2004 9:54 pm Post subject:
Right, the last 96 bytes tell you the 96 pixels, but they are flipped vertically... ... or w/e I had to take 12 bytes, and build it from the bottom up.. to have it display correctly
2dragons - Tue Jun 22, 2004 12:02 am Post subject:
That's true for bitmaps in general, but not in the 96 bytes commonly sent bank and forth between the many clients/servers of SS.
CypherJF - Tue Jun 22, 2004 12:25 am Post subject:
I can only tell you how I got the banner to look proper after retreiving it from Merv.
Smong - Thu Jun 24, 2004 2:41 pm Post subject:
Mr Ekted wrote:
Open any of the default SS graphics files (or a banner file) in Photoshop and you can see the SS palette.
ships.bm2 and tiles.bm2 have different palettes. I am assuming ships.bm2 uses the old palette.
Mr Ekted - Thu Jun 24, 2004 3:45 pm Post subject:
Bitmaps with a positive height (in BMP header) are stored bottom up, and with negative height are top down.