[Scummvm-cvs-logs] SF.net SVN: scummvm:[54975] scummvm/trunk/engines/sci/graphics/paint16.cpp
thebluegr at users.sourceforge.net
thebluegr at users.sourceforge.net
Mon Dec 20 13:21:18 CET 2010
Revision: 54975
http://scummvm.svn.sourceforge.net/scummvm/?rev=54975&view=rev
Author: thebluegr
Date: 2010-12-20 12:21:18 +0000 (Mon, 20 Dec 2010)
Log Message:
-----------
SCI: Fixed bug #3037945 - "PQ3 : Graphical Glitch with White Mercedes on Freeway"
Modified Paths:
--------------
scummvm/trunk/engines/sci/graphics/paint16.cpp
Modified: scummvm/trunk/engines/sci/graphics/paint16.cpp
===================================================================
--- scummvm/trunk/engines/sci/graphics/paint16.cpp 2010-12-20 12:19:28 UTC (rev 54974)
+++ scummvm/trunk/engines/sci/graphics/paint16.cpp 2010-12-20 12:21:18 UTC (rev 54975)
@@ -534,7 +534,20 @@
case SCI_DISPLAY_RESTOREUNDER:
bitsGetRect(argv[0], &rect);
rect.translate(-_ports->getPort()->left, -_ports->getPort()->top);
- bitsRestore(argv[0]);
+ if (g_sci->getGameId() == GID_PQ3 && g_sci->getEngineState()->currentRoomNumber() == 29) {
+ // WORKAROUND: PQ3 calls this without calling the associated
+ // kDisplay(SCI_DISPLAY_SAVEUNDER) call before. Theoretically,
+ // this would result in no rect getting restored. However, we
+ // still maintain a pointer from the previous room, resulting
+ // in invalidated content being restored on screen, and causing
+ // graphics glitches. Thus, we simply don't restore a rect in
+ // that room. The correct fix for this would be to erase hunk
+ // pointers when changing rooms, but this will suffice for now,
+ // as restoring from a totally invalid pointer is very rare.
+ // Fixes bug #3037945.
+ } else {
+ bitsRestore(argv[0]);
+ }
kernelGraphRedrawBox(rect);
// finishing loop
argc = 0;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list