News:

Don't forget to visit the main site! There's lots of helpful docs, patches, and more!

Main Menu

[SNES] How does the 4bpp format work?

Started by Zero One, February 15, 2016, 11:51:31 AM

Previous topic - Next topic

Zero One

I'm trying to get some graphics from the SNES to draw properly in C#, but I don't understand how the 4bpp format works.

The hex found at 0x1B0040 in Super Metroid:
00 00 E2 00 A4 00 E8 00 10 00 2E 00 4A 00 8E 00
FF 00 FF 00 FF 00 FF 00 FF 00 FF 00 FF 00 FF 00


is somehow supposed to form a %, but I don't know how. I've been doing some reading and I know it has something to do with bitplanes, but I haven't found any resource that explains it simply enough for me to understand. I'm hoping somebody here can help me with it.

P.JBoy

#1
First thing to read is this
...

Zero One

Ok, that and another document helped me a bit. So far, I know that the first row of bytes determines which pixels are coloured, but only bytes 00, 02, 04... etc. I did manage to successfully draw a % in Paint using the data from those bytes, but I still don't understand where the palette information comes from. Have I managed to pick a bad tile to learn this with?