[Scummvm-cvs-logs] CVS: scummvm/scumm gfx.cpp,1.9,1.10 gfx.h,1.1.1.1,1.2 scumm.h,1.9,1.10 scummvm.cpp,1.10,1.11 string.cpp,1.8,1.9

Pawe? Ko?odziejski aquadran at users.sourceforge.net
Sat Aug 31 12:27:01 CEST 2002


Update of /cvsroot/scummvm/scummvm/scumm
In directory usw-pr-cvs1:/tmp/cvs-serv8117

Modified Files:
	gfx.cpp gfx.h scumm.h scummvm.cpp string.cpp 
Log Message:
and more fixes

Index: gfx.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/gfx.cpp,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- gfx.cpp	31 Aug 2002 18:57:07 -0000	1.9
+++ gfx.cpp	31 Aug 2002 19:26:04 -0000	1.10
@@ -236,7 +236,7 @@
 	_vm->_system->copy_rect(ptr, _vm->_realWidth, x * 8, vs->topline + t, w, height);
 }
 
-void blit(byte *dst, byte *src, int w, int h)
+void Scumm::blit(byte *dst, byte *src, int w, int h)
 {
 	assert(h > 0);
 	assert(src != NULL);
@@ -244,8 +244,8 @@
 
 	do {
 		memcpy(dst, src, w);
-		dst += _vm->_realWidth;
-		src += _vm->_realWidth;
+		dst += _realWidth;
+		src += _realWidth;
 	} while (--h);
 }
 
@@ -920,7 +920,7 @@
 				if (flag & dbClear || !lightsOn)
 					clear8Col();
 				else
-					blit(_backbuff_ptr, _bgbak_ptr, 8, h);
+					_vm->blit(_backbuff_ptr, _bgbak_ptr, 8, h);
 			}
 		}
 		CHECK_HEAP;
@@ -2604,7 +2604,7 @@
 			if (_vm->hasCharsetMask(strip << 3, top, (strip + 1) << 3, bottom))
 				draw8ColWithMasking();
 			else
-				blit(_backbuff_ptr, _bgbak_ptr, 8, _numLinesToProcess);
+				_vm->blit(_backbuff_ptr, _bgbak_ptr, 8, _numLinesToProcess);
 		} else {
 			clear8Col();
 		}

Index: gfx.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/gfx.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -d -r1.1.1.1 -r1.2
--- gfx.h	21 Aug 2002 16:07:29 -0000	1.1.1.1
+++ gfx.h	31 Aug 2002 19:26:04 -0000	1.2
@@ -188,6 +188,4 @@
 	};
 };
 
-void blit(byte *dst, byte *src, int w, int h);
-
 #endif

Index: scumm.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/scumm.h,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- scumm.h	31 Aug 2002 13:29:09 -0000	1.9
+++ scumm.h	31 Aug 2002 19:26:04 -0000	1.10
@@ -839,6 +839,8 @@
 	void dissolveEffect(int width, int height);
 	void scrollEffect(int dir);
 
+	void blit(byte *dst, byte *src, int w, int h);
+
 	void decompressBomp(byte *dst, byte *src, int w, int h);
 	uint _shakeFrame;
 	int _screenStartStrip, _screenEndStrip;

Index: scummvm.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/scummvm.cpp,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- scummvm.cpp	31 Aug 2002 18:57:08 -0000	1.10
+++ scummvm.cpp	31 Aug 2002 19:26:04 -0000	1.11
@@ -91,8 +91,8 @@
 	if (_gameId == GID_ZAK256) {	// FmTowns is 320x240
 		_realWidth = 320;
 		_realHeight = 240;
-	} else {
-	if (_gameId == GID_CMI) {
+	}
+	else if (_gameId == GID_CMI) {
 		_realWidth = 640;
 		_realHeight = 480;
 	} else {

Index: string.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/string.cpp,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- string.cpp	31 Aug 2002 18:57:08 -0000	1.8
+++ string.cpp	31 Aug 2002 19:26:04 -0000	1.9
@@ -219,7 +219,7 @@
 
 	if (a && string[0].overhead != 0) {
 		if (!(_features & GF_AFTER_V6)) {
-			string[0].xpos = a->x - camera._cur.x + (_vm->_realWidth / 2);
+			string[0].xpos = a->x - camera._cur.x + (_realWidth / 2);
 
 			if (_vars[VAR_V5_TALK_STRING_Y] < 0) {
 				s = (a->scaley * (int)_vars[VAR_V5_TALK_STRING_Y]) / 0xFF;
@@ -451,7 +451,7 @@
 
 	buffer = charset._buffer + charset._bufPos;
 	string[0].ypos = camera._cur.y + 88;
-	string[0].xpos = (_vm->_realWidth / 2) - (charset.getStringWidth(0, buffer, 0) >> 1);
+	string[0].xpos = (_realWidth / 2) - (charset.getStringWidth(0, buffer, 0) >> 1);
 	if (string[0].xpos < 0)
 		string[0].xpos = 0;
 
@@ -958,7 +958,7 @@
 
 #if !defined(OLD)
 	if (_blitAlso)
-		blit(_backbuff_ptr, _bgbak_ptr, _width, _height);
+		_vm->blit(_backbuff_ptr, _bgbak_ptr, _width, _height);
 #endif
 
 	_left += _width;





More information about the Scummvm-git-logs mailing list