mirror of https://github.com/PCSX2/pcsx2.git
GS: optimize xxHash usage in palette hashing.
This commit is contained in:
parent
364199916f
commit
8db0b52821
|
@ -2510,7 +2510,10 @@ void GSTextureCache::Palette::InitializeTexture()
|
|||
|
||||
u64 GSTextureCache::PaletteKeyHash::operator()(const PaletteKey& key) const
|
||||
{
|
||||
return XXH3_64bits(key.clut, sizeof(key.clut[0]) * key.pal);
|
||||
ASSERT(key.pal == 16 || key.pal == 256);
|
||||
return key.pal == 16 ?
|
||||
XXH3_64bits(key.clut, sizeof(key.clut[0]) * 16) :
|
||||
XXH3_64bits(key.clut, sizeof(key.clut[0]) * 256);
|
||||
};
|
||||
|
||||
// GSTextureCache::PaletteKeyEqual
|
||||
|
|
Loading…
Reference in New Issue