document textures_sprites.c (#523)

This commit is contained in:
Fazana
2025-04-20 19:41:04 +01:00
committed by GitHub
parent 31acc13170
commit e980d79bc1
27 changed files with 456 additions and 395 deletions
+1 -1
View File
@@ -127,7 +127,7 @@
}
#if defined(F3DDKR_GBI)
// ?????? - Needed to modify this to work with matching build_tex_display_list
// ?????? - Needed to modify this to work with matching material_init
#undef TXL2WORDS_4b
#define TXL2WORDS_4b(txls) ((txls)/16)
#endif
+5
View File
@@ -75,4 +75,9 @@
// Used to make a u32 colour value look clearer. Transforms 0xFF0000FF to 255, 0, 0, 255
#define COLOUR_RGBA32(r, g, b, a) (((r << 24) | (g << 16) | (b << 8) | a))
// A few systems in the game use an array as a cache table. This gives you the asset ID
#define ASSETCACHE_ID(x) ((x << 1) + 0)
// A few systems in the game use an array as a cache table. This gives you the pointer to the asset
#define ASSETCACHE_PTR(x) ((x << 1) + 1)
#endif
+1 -1
View File
@@ -163,7 +163,7 @@ typedef struct Sprite {
/* 0x00 */ s16 baseTextureId;
/* 0x02 */ s16 numberOfFrames; // 1 means static texture
/* 0x04 */ s16 numberOfInstances;
/* 0x06 */ s16 unk6;
/* 0x06 */ s16 drawFlags;
/* 0x08 */ TextureHeader **frames;
union {
/* 0x0C */ u8 val[1]; // Actual size varies.