mirror of
https://github.com/blawar/GLideN64.git
synced 2024-07-04 10:03:36 +00:00
Fix TextureCache::_updateBackground():
Load texture image with its actual size, not cast to power of two sizes. This allows to wrap it easily.
This commit is contained in:
parent
a849fb81e5
commit
799638c29b
15
Textures.cpp
15
Textures.cpp
|
@ -673,17 +673,17 @@ void TextureCache::_updateBackground()
|
|||
pCurrent->palette = gSP.bgImage.palette;
|
||||
pCurrent->maskS = 0;
|
||||
pCurrent->maskT = 0;
|
||||
pCurrent->mirrorS = 0;
|
||||
pCurrent->mirrorT = 0;
|
||||
pCurrent->clampS = 1;
|
||||
pCurrent->clampT = 1;
|
||||
pCurrent->mirrorS = 1;
|
||||
pCurrent->mirrorT = 1;
|
||||
pCurrent->clampS = 0;
|
||||
pCurrent->clampT = 0;
|
||||
pCurrent->line = 0;
|
||||
pCurrent->tMem = 0;
|
||||
pCurrent->lastDList = RSP.DList;
|
||||
pCurrent->frameBufferTexture = FALSE;
|
||||
|
||||
pCurrent->realWidth = pow2( gSP.bgImage.width );
|
||||
pCurrent->realHeight = pow2( gSP.bgImage.height );
|
||||
pCurrent->realWidth = gSP.bgImage.width;
|
||||
pCurrent->realHeight = gSP.bgImage.height;
|
||||
|
||||
pCurrent->scaleS = 1.0f / (f32)(pCurrent->realWidth);
|
||||
pCurrent->scaleT = 1.0f / (f32)(pCurrent->realHeight);
|
||||
|
@ -691,6 +691,9 @@ void TextureCache::_updateBackground()
|
|||
pCurrent->shiftScaleS = 1.0f;
|
||||
pCurrent->shiftScaleT = 1.0f;
|
||||
|
||||
pCurrent->offsetS = 0.5f;
|
||||
pCurrent->offsetT = 0.5f;
|
||||
|
||||
_loadBackground(pCurrent);
|
||||
activateTexture(0, pCurrent);
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user