mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
d3d9: Correct replaced texture format.
This was causing the row width to be wrong for many textures too, which was generating errors.
This commit is contained in:
parent
dddb3c39eb
commit
b30d0e8cec
1 changed files with 3 additions and 1 deletions
|
@ -1370,7 +1370,9 @@ void TextureCacheDX9::LoadTextureLevel(TexCacheEntry &entry, ReplacedTexture &re
|
|||
int levels = scaleFactor == 1 ? maxLevel + 1 : 1;
|
||||
int tw = w, th = h;
|
||||
D3DFORMAT tfmt = (D3DFORMAT)D3DFMT(dstFmt);
|
||||
if (!replaced.GetSize(level, tw, th)) {
|
||||
if (replaced.GetSize(level, tw, th)) {
|
||||
tfmt = (D3DFORMAT)D3DFMT(ToD3D9Format(replaced.Format(level)));
|
||||
} else {
|
||||
tw *= scaleFactor;
|
||||
th *= scaleFactor;
|
||||
if (scaleFactor > 1) {
|
||||
|
|
Loading…
Add table
Reference in a new issue