diff options
author | Paul Gilbert | 2016-10-04 20:04:49 -0400 |
---|---|---|
committer | Paul Gilbert | 2016-10-04 20:04:49 -0400 |
commit | 0a8f47a3ae5d7b69a189a448714620e4cdc9fa4e (patch) | |
tree | 868097bb3f7e316e06297b8f4ed2f5636acae916 /engines/titanic/support/video_surface.cpp | |
parent | 1f9b62ee8e560ea06a7cdc102d6509707c498287 (diff) | |
download | scummvm-rg350-0a8f47a3ae5d7b69a189a448714620e4cdc9fa4e.tar.gz scummvm-rg350-0a8f47a3ae5d7b69a189a448714620e4cdc9fa4e.tar.bz2 scummvm-rg350-0a8f47a3ae5d7b69a189a448714620e4cdc9fa4e.zip |
TITANIC: Workaround for incorrect transparency check in getPixel
Diffstat (limited to 'engines/titanic/support/video_surface.cpp')
-rw-r--r-- | engines/titanic/support/video_surface.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/engines/titanic/support/video_surface.cpp b/engines/titanic/support/video_surface.cpp index f88f05327f..1991d7423f 100644 --- a/engines/titanic/support/video_surface.cpp +++ b/engines/titanic/support/video_surface.cpp @@ -511,8 +511,10 @@ uint16 OSVideoSurface::getPixel(const Common::Point &pt) { if (pt.x >= 0 && pt.y >= 0 && pt.x < getWidth() && pt.y < getHeight()) { if (_transparencySurface) { + // WORKAROUND: Original had the setRow _flipVertically check in reverse. + // Pretty sure putting it the way is below is the correct way CTransparencySurface transSurface(&_transparencySurface->rawSurface(), _transparencyMode); - transSurface.setRow(_flipVertically ? pt.y : getHeight() - pt.y - 1); + transSurface.setRow(_flipVertically ? getHeight() - pt.y - 1 : pt.y); transSurface.setCol(pt.x); if (transSurface.isPixelTransparent2()) |