aboutsummaryrefslogtreecommitdiff
path: root/graphics/surface.h
diff options
context:
space:
mode:
authorJohannes Schickel2011-04-17 17:30:44 +0200
committerJohannes Schickel2011-04-17 20:58:08 +0200
commit3fd919060ca6bbf896680f3548bfaac020900d42 (patch)
treeb8d96772e727cb8932c54987d296a4baf93fe087 /graphics/surface.h
parent41586398abb45c6e0551da729471c4215299d131 (diff)
downloadscummvm-rg350-3fd919060ca6bbf896680f3548bfaac020900d42.tar.gz
scummvm-rg350-3fd919060ca6bbf896680f3548bfaac020900d42.tar.bz2
scummvm-rg350-3fd919060ca6bbf896680f3548bfaac020900d42.zip
GRPAHICS: Do not access Surface::bytesPerPixel anymore.
Diffstat (limited to 'graphics/surface.h')
-rw-r--r--graphics/surface.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/graphics/surface.h b/graphics/surface.h
index 3cc69fafdd..d25ebffcc5 100644
--- a/graphics/surface.h
+++ b/graphics/surface.h
@@ -90,7 +90,7 @@ struct Surface {
* @return Pointer to the pixel.
*/
inline const void *getBasePtr(int x, int y) const {
- return (const byte *)(pixels) + y * pitch + x * bytesPerPixel;
+ return (const byte *)(pixels) + y * pitch + x * format.bytesPerPixel;
}
/**
@@ -101,7 +101,7 @@ struct Surface {
* @return Pointer to the pixel.
*/
inline void *getBasePtr(int x, int y) {
- return static_cast<byte *>(pixels) + y * pitch + x * bytesPerPixel;
+ return static_cast<byte *>(pixels) + y * pitch + x * format.bytesPerPixel;
}
/**