NCGR (NITRO-System Character Graphics for Runtime) 2D engine character or bitmap graphics. When they store character graphics they will usually have the NCGR extension, and for bitmap graphics will have the NCBR extension. It follows the NNS G2D Binary File Format. NCGR files use file signature 'NCGR'.

CHAR Block#

The CHAR block stores the graphics data for the file. The structure of this block is as follows:

OffsetTypeMeaning
0x00 u16 Width of graphics in characters. If the file is storing graphics with 1D mapping mode, this field is not used and usually set to 0xFFFF.
0x02 u16 Height of graphics in characters. Unused in 1D mapping mode.
0x04 u32 Color format. This is the same as the texture formats used in TEXIMAGE_PARAM, where only values of 3 and 4 (palette16 and palette256) are used.
0x08 u32 Mapping mode. This can be 2D (0x000000), 1D 32K (0x000010), 1D 64K (0x100010), 1D 128K (0x200010), or 1D 128K (0x300010).
0x0C u32 Graphics type. For character graphics, this will be 0. For bitmap graphics, this will be 1.
0x10 u32 Size of graphics data.
0x14 void * Pointer to graphics data. This is relative to the start of this structure and fixed up at load time.

CPOS Block#

The CPOS (character position) block stores information about how to load the file into VRAM for a background layer. This block allows for loading only part of the graphics data into VRAM. This block is structures as follows:

OffsetTypeMeaning
0x00 u16 X (should be 0).
0x02 u16 Y
0x04 u16 Width
0x06 u16 Height

Add new attachment

Only authorized users are allowed to upload new attachments.
« This page (revision-2) was last changed on 01-May-2024 19:00 by Garhoogin