[Scummvm-cvs-logs] SF.net SVN: scummvm: [23175] scummvm/branches/branch-0-9-0/engines/scumm
kirben at users.sourceforge.net
kirben at users.sourceforge.net
Mon Jun 19 06:12:26 CEST 2006
Revision: 23175
Author: kirben
Date: 2006-06-18 21:12:16 -0700 (Sun, 18 Jun 2006)
ViewCVS: http://svn.sourceforge.net/scummvm/?rev=23175&view=rev
Log Message:
-----------
Fix screen scrolling glitch when looking at the top of closet in parents room of DOS version of fbear
Modified Paths:
--------------
scummvm/branches/branch-0-9-0/engines/scumm/gfx.cpp
scummvm/branches/branch-0-9-0/engines/scumm/he/script_v60he.cpp
scummvm/branches/branch-0-9-0/engines/scumm/script_v5.cpp
scummvm/branches/branch-0-9-0/engines/scumm/script_v6.cpp
scummvm/branches/branch-0-9-0/engines/scumm/scumm.h
Modified: scummvm/branches/branch-0-9-0/engines/scumm/gfx.cpp
===================================================================
--- scummvm/branches/branch-0-9-0/engines/scumm/gfx.cpp 2006-06-19 04:09:39 UTC (rev 23174)
+++ scummvm/branches/branch-0-9-0/engines/scumm/gfx.cpp 2006-06-19 04:12:16 UTC (rev 23175)
@@ -3003,16 +3003,6 @@
if (!(_game.features & GF_NEW_CAMERA))
camera._last.x = camera._cur.x;
- if (_switchRoomEffect >= 130 && _switchRoomEffect <= 133) {
- // We're going to use scrollEffect(), so we'll need a copy of
- // the current VirtScreen zero.
-
- free(_scrollBuffer);
- _scrollBuffer = (byte *) malloc(vs->h * vs->pitch);
- memcpy(_scrollBuffer, vs->getPixels(0, 0), vs->h * vs->pitch);
- }
-
-
if (_screenEffectFlag && effect != 0) {
// Fill screen 0 with black
@@ -3054,6 +3044,18 @@
_screenEffectFlag = false;
}
+void ScummEngine::setScrollBuffer() {
+ if (_switchRoomEffect >= 130 && _switchRoomEffect <= 133) {
+ // We're going to use scrollEffect(), so we'll need a copy of
+ // the current VirtScreen zero.
+ VirtScreen *vs = &virtscr[0];
+
+ free(_scrollBuffer);
+ _scrollBuffer = (byte *) malloc(vs->h * vs->pitch);
+ memcpy(_scrollBuffer, vs->getPixels(0, 0), vs->h * vs->pitch);
+ }
+}
+
/**
* Perform a transition effect. There are four different effects possible:
* 0: Iris effect
Modified: scummvm/branches/branch-0-9-0/engines/scumm/he/script_v60he.cpp
===================================================================
--- scummvm/branches/branch-0-9-0/engines/scumm/he/script_v60he.cpp 2006-06-19 04:09:39 UTC (rev 23174)
+++ scummvm/branches/branch-0-9-0/engines/scumm/he/script_v60he.cpp 2006-06-19 04:12:16 UTC (rev 23175)
@@ -519,6 +519,7 @@
} else if (a) {
_switchRoomEffect = (byte)(a & 0xFF);
_switchRoomEffect2 = (byte)(a >> 8);
+ setScrollBuffer();
} else {
fadeIn(_newEffect);
}
Modified: scummvm/branches/branch-0-9-0/engines/scumm/script_v5.cpp
===================================================================
--- scummvm/branches/branch-0-9-0/engines/scumm/script_v5.cpp 2006-06-19 04:09:39 UTC (rev 23174)
+++ scummvm/branches/branch-0-9-0/engines/scumm/script_v5.cpp 2006-06-19 04:12:16 UTC (rev 23175)
@@ -1926,6 +1926,7 @@
}
_switchRoomEffect = (byte)(a & 0xFF);
_switchRoomEffect2 = (byte)(a >> 8);
+ setScrollBuffer();
} else {
fadeIn(_newEffect);
}
Modified: scummvm/branches/branch-0-9-0/engines/scumm/script_v6.cpp
===================================================================
--- scummvm/branches/branch-0-9-0/engines/scumm/script_v6.cpp 2006-06-19 04:09:39 UTC (rev 23174)
+++ scummvm/branches/branch-0-9-0/engines/scumm/script_v6.cpp 2006-06-19 04:12:16 UTC (rev 23175)
@@ -1707,6 +1707,7 @@
if (a) {
_switchRoomEffect = (byte)(a & 0xFF);
_switchRoomEffect2 = (byte)(a >> 8);
+ setScrollBuffer();
} else {
fadeIn(_newEffect);
}
Modified: scummvm/branches/branch-0-9-0/engines/scumm/scumm.h
===================================================================
--- scummvm/branches/branch-0-9-0/engines/scumm/scumm.h 2006-06-19 04:09:39 UTC (rev 23174)
+++ scummvm/branches/branch-0-9-0/engines/scumm/scumm.h 2006-06-19 04:12:16 UTC (rev 23175)
@@ -1078,6 +1078,7 @@
protected:
void fadeIn(int effect);
void fadeOut(int effect);
+ void setScrollBuffer();
void unkScreenEffect6();
void transitionEffect(int a);
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