CLUT Optimization
-
- Posts: 75
- Joined: Mon Sep 19, 2005 5:41 am
CLUT Optimization
Does anyone know if there is the same huge performance hit with CLUT entries referenced in local RAM as there is with the texture data? I was thinking that sceGuClutLoad() might just load a table in VRAM/other ram, rather than just tell the gu where the palette data is. does anyone know?
That's true, the only hit you may take is that the palette upload will be slightly slower.
Though I have not actually benchmarked and seen if there is a measurable difference.
Though I have not actually benchmarked and seen if there is a measurable difference.
http://www.dtek.chalmers.se/~tronic/PSPTexTool.zip Free texture converter for PSP with source. More to come.
-
- Posts: 75
- Joined: Mon Sep 19, 2005 5:41 am
you should see a good speed
advantage by loading clut
in user space mem (24MB) and then
transfer to VRAM(2MB) since transfer
from main mem to gu mem is around
150MB/s bandwidth ;)
of course you could just load direct to
VRAM and use your color lookup table
through there and keeping it a constant
address in VRAM, considering gu ram
has 500MB/s bandwidth then this
should be more than ample to
whatever your clut needs are ;)
remember copying from memstick
to user mem and gu mem is the same
speed or bandwidth so whatever method
works for you is best .....first is generally
used if say VRAM is used exstensively
advantage by loading clut
in user space mem (24MB) and then
transfer to VRAM(2MB) since transfer
from main mem to gu mem is around
150MB/s bandwidth ;)
of course you could just load direct to
VRAM and use your color lookup table
through there and keeping it a constant
address in VRAM, considering gu ram
has 500MB/s bandwidth then this
should be more than ample to
whatever your clut needs are ;)
remember copying from memstick
to user mem and gu mem is the same
speed or bandwidth so whatever method
works for you is best .....first is generally
used if say VRAM is used exstensively
10011011 00101010 11010111 10001001 10111010
-
- Posts: 75
- Joined: Mon Sep 19, 2005 5:41 am
Update:
Just as a test, I loaded my CLUT entries into VRAM, then did my sceGuClutLoad() pointing from VRAM and there was no noticible performance improvement. I make heavy use of CLUT textures and am pretty sure I am rendering bound so my conclusion is that it looks like when the GU is retrieiving a texel with CLUT textures it gets the color from a private look-up table that is filled with sceGuClutLoad(), rather than pointing to an address referenced in sceGuClutLoad().
Just as a test, I loaded my CLUT entries into VRAM, then did my sceGuClutLoad() pointing from VRAM and there was no noticible performance improvement. I make heavy use of CLUT textures and am pretty sure I am rendering bound so my conclusion is that it looks like when the GU is retrieiving a texel with CLUT textures it gets the color from a private look-up table that is filled with sceGuClutLoad(), rather than pointing to an address referenced in sceGuClutLoad().