[Scummvm-cvs-logs] CVS: scummvm/scumm akos.cpp,1.188,1.189 gfx.cpp,2.353,2.354 script_v72he.cpp,2.134,2.135

Gregory Montoir cyx at users.sourceforge.net
Tue Sep 28 15:00:36 CEST 2004


Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24440/scumm

Modified Files:
	akos.cpp gfx.cpp script_v72he.cpp 
Log Message:
cleanup

Index: akos.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/akos.cpp,v
retrieving revision 1.188
retrieving revision 1.189
diff -u -d -r1.188 -r1.189
--- akos.cpp	28 Sep 2004 19:28:57 -0000	1.188
+++ akos.cpp	28 Sep 2004 21:53:19 -0000	1.189
@@ -1219,8 +1219,8 @@
 	}
 
 	dst.top = _actorY + ymoveCur;
-	dst.right = dst.left + _width - 1;
-	dst.bottom = dst.top + _height - 1;
+	dst.right = dst.left + _width;
+	dst.bottom = dst.top + _height;
 
 	dst.clip(_clipOverride);
 	src = dst;
@@ -1228,7 +1228,6 @@
 
 	_vm->markRectAsDirty(kMainVirtScreen, dst, _actorID);
 
-	// cyx: are these variables really useful ?
 	if (_draw_top > dst.top)
 		_draw_top = dst.top;
 	if (_draw_bottom < dst.bottom)

Index: gfx.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/gfx.cpp,v
retrieving revision 2.353
retrieving revision 2.354
diff -u -d -r2.353 -r2.354
--- gfx.cpp	28 Sep 2004 21:42:34 -0000	2.353
+++ gfx.cpp	28 Sep 2004 21:53:29 -0000	2.354
@@ -1450,21 +1450,19 @@
 }
 
 static bool calcClipRects(int dst_w, int dst_h, int src_x, int src_y, int src_w, int src_h, const Common::Rect *rect, Common::Rect &srcRect, Common::Rect &dstRect) {
-	srcRect = Common::Rect(0, 0, src_w, src_h);
-	dstRect = Common::Rect(src_x, src_y, src_x + src_w, src_y + src_h);
 	Common::Rect r3;
-
 	if (rect) {
 		r3 = *rect;
-		Common::Rect r4(0, 0, dst_w, dst_h);
+		Common::Rect r4(dst_w, dst_h);
 		if (r3.intersects(r4)) {
 			r3.clip(r4);
 		} else {
 			return false;
 		}
 	} else {
-		r3 = Common::Rect(0, 0, dst_w, dst_h);
+		r3 = Common::Rect(dst_w, dst_h);
 	}
+	dstRect = Common::Rect(src_x, src_y, src_x + src_w, src_y + src_h);
 	dstRect.clip(r3);
 	srcRect = dstRect;
 	srcRect.moveTo(0, 0);

Index: script_v72he.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v72he.cpp,v
retrieving revision 2.134
retrieving revision 2.135
diff -u -d -r2.134 -r2.135
--- script_v72he.cpp	28 Sep 2004 20:19:28 -0000	2.134
+++ script_v72he.cpp	28 Sep 2004 21:53:29 -0000	2.135
@@ -1475,7 +1475,7 @@
 			cw = pvs->w;
 			ch = pvs->h;
 		}
-		Common::Rect rScreen(0, 0, cw - 1, ch - 1);
+		Common::Rect rScreen(cw, ch);
 		if (pwi->flags & 0x80) {    
 //  		drawWizImageHelper2(p, wizd, cw, ch, x1, y1, width, height, &rScreen, 0, 2);
 			warning("drawWizImage() unhandled flag 0x80");
@@ -1489,7 +1489,7 @@
 			warning("printing Wiz image is unimplemented");
 			dst = NULL;
 		} else if (!(pwi->flags & 0x20)) {
-			Common::Rect rImage(pwi->x1, pwi->y1, pwi->x1 + width - 1, pwi->y1 + height - 1);
+			Common::Rect rImage(pwi->x1, pwi->y1, pwi->x1 + width, pwi->y1 + height);
 			if (rImage.intersects(rScreen)) {
 				rImage.clip(rScreen);
 				if (pwi->flags & 0x18) {





More information about the Scummvm-git-logs mailing list