Hi,
I fail to see the point behind these 2 texture modes (especially the later one), did i miss something obvious ?
16 bits & 32 bits indexed texture modes ?
Re: 16 bits & 32 bits indexed texture modes ?
indexed 32bit textures for example take only 1/4 of the size (+ max 256*4 bytes palette data) of a regular 32bit texture.hitchhikr wrote: I fail to see the point behind these 2 texture modes (especially the later one), did i miss something obvious ?
I thought it was the T8 (8 bits indexed) textures that took 1/4 the size of rgba 32bits textures ?
Apparently, I AM missing something crucial about the inner working of these indexed modes, care to explain this clearly to me ? :D
Basically that's how i see it:
T4 < 4 bits / 16 colors
T8 < 8 bits / 256 colors
T16 < 16 bits / 65536 colors
T32 < 32 bits / 4gigs colors
I thought that the T16 & T32 modes were made to use more than 256 or 65536 colors but they appear like redundants modes with the RGB ones to me.
(I think the modes (clutmodes) of the palette themselves are independants of the resolutions of the indices tables or ?)
Apparently, I AM missing something crucial about the inner working of these indexed modes, care to explain this clearly to me ? :D
Basically that's how i see it:
T4 < 4 bits / 16 colors
T8 < 8 bits / 256 colors
T16 < 16 bits / 65536 colors
T32 < 32 bits / 4gigs colors
I thought that the T16 & T32 modes were made to use more than 256 or 65536 colors but they appear like redundants modes with the RGB ones to me.
(I think the modes (clutmodes) of the palette themselves are independants of the resolutions of the indices tables or ?)
Last edited by hitchhikr on Sat May 06, 2006 11:34 pm, edited 1 time in total.
as far as i know there are only T4 and T8 for indexed textures.
so with a clut mode of GU_PSM_8888 and a T8 indexed texture, you're using 1byte indices to reference into a 32bit palette. so 1 pixel is represented by 1byte instead of 4...
edit: T8 means 8bits to represent the index, not the color value. the color values come from your palette
so with a clut mode of GU_PSM_8888 and a T8 indexed texture, you're using 1byte indices to reference into a 32bit palette. so 1 pixel is represented by 1byte instead of 4...
edit: T8 means 8bits to represent the index, not the color value. the color values come from your palette
Code: Select all
#define GU_PSM_5650 (0)
#define GU_PSM_5551 (1)
#define GU_PSM_4444 (2)
#define GU_PSM_8888 (3)
#define GU_PSM_T4 (4)
#define GU_PSM_T8 (5)
#define GU_PSM_T16 (6)
#define GU_PSM_T32 (7)
#define GU_PSM_DXT1 (8)
#define GU_PSM_DXT3 (9)
#define GU_PSM_DXT5 (10)
http://psp.jim.sh/pspsdk-doc/pspgu_8h.html
Apparently you can specify an offset and a bitmask when setting up your color table, so with a larger palette you could use that for some effects, although I can't really think of anything to use it for. Other people have had trouble getting it to work, though. There's a thread about it somewhere here from a while back.
Edit:
http://forums.ps2dev.org/viewtopic.php?t=4866
http://forums.ps2dev.org/viewtopic.php?t=4941
Edit:
http://forums.ps2dev.org/viewtopic.php?t=4866
http://forums.ps2dev.org/viewtopic.php?t=4941