We've just updated MediaWiki and its underlying software. If anything doesn't look or work quite right, please mention it to us. --RanAS

CGRAM: Difference between revisions

From SnesLab
Jump to: navigation, search
(flowing direct/indirect color into article main body)
(what addresses are second half)
Line 5: Line 5:
* bits 10 to 14 are the blue intensity
* bits 10 to 14 are the blue intensity


In all background modes, sprites use the second half of CGRAM.
In all background modes, sprites use the second half of CGRAM (addresses 80h to FFh).


When using CGRAM, color entries can be one of 32,768 colors from the master palette.
When using CGRAM, color entries can be one of 32,768 colors from the master palette.

Revision as of 21:56, 28 December 2023

CGRAM (Color Generator[2] RAM) is where palettes are stored for indirect color. The SNES uses 15-bit color here. It is a total of 512 bytes. For each of the 256 color entries:

  • bits 0 to 4 are the red intensity
  • bits 5 to 9 are the green intensity
  • bits 10 to 14 are the blue intensity

In all background modes, sprites use the second half of CGRAM (addresses 80h to FFh).

When using CGRAM, color entries can be one of 32,768 colors from the master palette.

Direct Color is a technique that does not use CGRAM.

See Also

References

  1. Appendix 17 of the official Super Nintendo development manual on CG-RAM
  2. https://problemkaputt.de/fullsnes.htm#snesmemorycgramaccesspalettememory