aboutsummaryrefslogtreecommitdiff
path: root/engines/scumm/he
diff options
context:
space:
mode:
authorJohannes Schickel2013-08-02 22:23:00 +0200
committerJohannes Schickel2013-08-03 02:52:31 +0200
commitc05cb7f3bbcf4d64d4a938e0eb42065d8f3d3038 (patch)
tree1a2b4f8a216de2f2f742a9c9ef68b46c51603883 /engines/scumm/he
parent4790a4abd5c157254cab069bc34aa8ef8347f668 (diff)
downloadscummvm-rg350-c05cb7f3bbcf4d64d4a938e0eb42065d8f3d3038.tar.gz
scummvm-rg350-c05cb7f3bbcf4d64d4a938e0eb42065d8f3d3038.tar.bz2
scummvm-rg350-c05cb7f3bbcf4d64d4a938e0eb42065d8f3d3038.zip
SCUMM: Prefer getBasePtr over direct Surface::pixels access.
Diffstat (limited to 'engines/scumm/he')
-rw-r--r--engines/scumm/he/animation_he.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/engines/scumm/he/animation_he.cpp b/engines/scumm/he/animation_he.cpp
index be17a3b305..7ae5547702 100644
--- a/engines/scumm/he/animation_he.cpp
+++ b/engines/scumm/he/animation_he.cpp
@@ -90,7 +90,7 @@ void MoviePlayer::copyFrameToBuffer(byte *dst, int dstType, uint x, uint y, uint
if (!surface)
return;
- byte *src = (byte *)surface->pixels;
+ const byte *src = (const byte *)surface->getBasePtr(0, 0);
if (_video->hasDirtyPalette())
_vm->setPaletteFromPtr(_video->getPalette(), 256);
@@ -119,7 +119,7 @@ void MoviePlayer::copyFrameToBuffer(byte *dst, int dstType, uint x, uint y, uint
dst += y * pitch + x * 2;
do {
for (uint i = 0; i < w; i++) {
- uint16 color = *((uint16 *)src + i);
+ uint16 color = *((const uint16 *)src + i);
switch (dstType) {
case kDstScreen:
WRITE_UINT16(dst + i * 2, color);