User Tools

Site Tools


extreme_g:texture_banks

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

extreme_g:texture_banks [2020/06/14 20:39] (current)
shygoo created
Line 1: Line 1:
 +====== Extreme-G Texture Bank Formats =====
 +
 +Extreme-G'​s level GFX commands use textures from three bank types.
 +
 +----
 +===== "​Level"​ texture banks =====
 +
 +This bank type contains CI8/CI4 textures that are unique to each level.
 +Each bank of this type consists of two files referred to by the [[extreme_g:​rom_map#​level_header_structure|level header structures]].
 +The first file contains a table of texture meta data structures and the second file simply contains the texture data.
 +
 +==== Texture meta data structure ====
 +
 +^Offset^Description^
 +|00|8-bit texture width|
 +|01|8-bit texture height|
 +|02|8-bit format ID (01 = CI8, 02 = CI4)|
 +|03|Padding byte|
 +|04|32-bit offset of a texture'​s color index data|
 +|08|32-bit offset of a texture'​s palette data|
 +
 +Used by [[extreme_g:​gfx_collision_commands#​level_texture|GFX command 02: "​level_texture"​]].
 +
 +----
 +===== "​Global"​ texture bank =====
 +
 +This bank type contains CI8 textures that are shared between all levels. The global texture bank is stored LZHUF-compressed at 000C3400 in ROM.
 +
 +==== High level structure ====
 +^Offset^Description^
 +|00|32-bit offset pointing to a single palette at the end of the bank|
 +|04|4 padding bytes|
 +|08|Texture meta data structure table|
 +|...|Texture color index data|
 +|...|0x200 byte texture palette|
 +
 +==== Texture meta data structure ===
 +^Offset^Description^
 +|00|32-bit offset of a texture'​s color index data|
 +|04|16-bit texture width|
 +|06|16-bit texture height|
 +
 +Used by [[extreme_g:​gfx_collision_commands#​global_texture|GFX command 0C: "​global_texture"​]].
 +
 +----
 +===== "​Common"​ texture banks =====
 +
 +This bank type contains CI8 textures that are shared between some levels.
 +The structure of this bank type is the same as the "​Global"​ texture bank's structure described above.
 +
 +The ROM addresses of these banks are defined in [[extreme_g:​rom_map#​LZHUF table 00001450|LZHUF Table 00001450]]. ​
 +
 +Used by [[extreme_g:​gfx_collision_commands#​common_texture|GFX command 0D: "​common_texture"​]].
 +
  
extreme_g/texture_banks.txt ยท Last modified: 2020/06/14 20:39 by shygoo