mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Remove redundant call to ConvertColors, skip a copy when possible
This commit is contained in:
parent
5de7bb2e2d
commit
1fb7cdfcd2
1 changed files with 1 additions and 2 deletions
|
@ -1248,7 +1248,7 @@ void *TextureCache::DecodeTextureLevel(GETextureFormat format, GEPaletteFormat c
|
|||
case GE_TFMT_8888:
|
||||
if (!gstate.isTextureSwizzled()) {
|
||||
// Special case: if we don't need to deal with packing, we don't need to copy.
|
||||
if (w == bufw) {
|
||||
if (gl_extensions.EXT_unpack_subimage || w == bufw) {
|
||||
finalBuf = Memory::GetPointer(texaddr);
|
||||
} else {
|
||||
int len = bufw * h;
|
||||
|
@ -1262,7 +1262,6 @@ void *TextureCache::DecodeTextureLevel(GETextureFormat format, GEPaletteFormat c
|
|||
tmpTexBuf32.resize(std::max(bufw, w) * h);
|
||||
finalBuf = UnswizzleFromMem(texaddr, bufw, 4, level);
|
||||
}
|
||||
ConvertColors(finalBuf, finalBuf, dstFmt, bufw * h);
|
||||
break;
|
||||
|
||||
case GE_TFMT_DXT1:
|
||||
|
|
Loading…
Add table
Reference in a new issue