diff options
author | Johannes Schickel | 2013-08-03 02:44:15 +0200 |
---|---|---|
committer | Johannes Schickel | 2013-08-03 04:02:53 +0200 |
commit | 7455cd4e35cb8d65e9adef86062f0566bc96e4ba (patch) | |
tree | c3f637252d0c01f55edbc08ae1b506b482295d2b /engines/toon | |
parent | b125aa953b04c8411b00aa89ae4f19786232dbd9 (diff) | |
download | scummvm-rg350-7455cd4e35cb8d65e9adef86062f0566bc96e4ba.tar.gz scummvm-rg350-7455cd4e35cb8d65e9adef86062f0566bc96e4ba.tar.bz2 scummvm-rg350-7455cd4e35cb8d65e9adef86062f0566bc96e4ba.zip |
TOON: Take advantage of Surface::getPixels.
Diffstat (limited to 'engines/toon')
-rw-r--r-- | engines/toon/anim.cpp | 2 | ||||
-rw-r--r-- | engines/toon/movie.cpp | 2 | ||||
-rw-r--r-- | engines/toon/toon.cpp | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/engines/toon/anim.cpp b/engines/toon/anim.cpp index aecf341079..78d3954325 100644 --- a/engines/toon/anim.cpp +++ b/engines/toon/anim.cpp @@ -231,7 +231,7 @@ void Animation::drawFrameWithMaskAndScale(Graphics::Surface &surface, int32 fram int32 destPitch = surface.pitch; int32 destPitchMask = mask->getWidth(); uint8 *c = _frames[frame]._data; - uint8 *curRow = (uint8 *)surface.getBasePtr(0, 0); + uint8 *curRow = (uint8 *)surface.getPixels(); uint8 *curRowMask = mask->getDataPtr(); bool shadowFlag = false; diff --git a/engines/toon/movie.cpp b/engines/toon/movie.cpp index 962b73dfa7..f0463a52e1 100644 --- a/engines/toon/movie.cpp +++ b/engines/toon/movie.cpp @@ -112,7 +112,7 @@ bool Movie::playVideo(bool isFirstIntroVideo) { } _vm->_system->unlockScreen(); } else { - _vm->_system->copyRectToScreen(frame->getBasePtr(0, 0), frame->pitch, 0, 0, frame->w, frame->h); + _vm->_system->copyRectToScreen(frame->getPixels(), frame->pitch, 0, 0, frame->w, frame->h); // WORKAROUND: There is an encoding glitch in the first intro video. This hides this using the adjacent pixels. if (isFirstIntroVideo) { diff --git a/engines/toon/toon.cpp b/engines/toon/toon.cpp index 2f5c810811..286bcf1941 100644 --- a/engines/toon/toon.cpp +++ b/engines/toon/toon.cpp @@ -499,7 +499,7 @@ void ToonEngine::copyToVirtualScreen(bool updateScreen) { if (_dirtyAll || _gameState->_currentScrollValue != lastScroll) { // we have to refresh everything in case of scrolling. - _system->copyRectToScreen((byte *)_mainSurface->getBasePtr(0, 0) + state()->_currentScrollValue, TOON_BACKBUFFER_WIDTH, 0, 0, TOON_SCREEN_WIDTH, TOON_SCREEN_HEIGHT); + _system->copyRectToScreen((byte *)_mainSurface->getPixels() + state()->_currentScrollValue, TOON_BACKBUFFER_WIDTH, 0, 0, TOON_SCREEN_WIDTH, TOON_SCREEN_HEIGHT); } else { int32 offX = 0; |