sword1: enable psx background caching for screen 54 (bull's head) too

svn-id: r39475
This commit is contained in:
Fabio Battaglia 2009-03-17 07:46:04 +00:00
parent 92c9365650
commit 3c9b4e0f07

View File

@ -372,11 +372,11 @@ void Screen::draw(void) {
renderParallax(_parallax[0]);
uint8 *src = _layerBlocks[0];
uint8 *dest = _screenBuf;
uint8 *indxScreen = NULL;
if(SwordEngine::isPsx()) {
indxScreen = psxShrinkedBackgroundToIndexed(_layerBlocks[0], _scrnSizeX, _scrnSizeY);
src = indxScreen;
if (!_psxCache.decodedBackground)
_psxCache.decodedBackground = psxShrinkedBackgroundToIndexed(_layerBlocks[0], _scrnSizeX, _scrnSizeY);
src = _psxCache.decodedBackground;
}
for (uint16 cnty = 0; cnty < _scrnSizeY; cnty++)
@ -388,8 +388,6 @@ void Screen::draw(void) {
src++;
}
free(indxScreen);
} else if (!(SwordEngine::isPsx())) {
memcpy(_screenBuf, _layerBlocks[0], _scrnSizeX * _scrnSizeY);
} else { //We are using PSX version