[Scummvm-cvs-logs] CVS: scummvm/saga image.cpp,1.26,1.27 saga.h,1.134,1.135 scene.cpp,1.155,1.156

Eugene Sandulenko sev at users.sourceforge.net
Mon Oct 17 07:22:20 CEST 2005


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

Modified Files:
	image.cpp saga.h scene.cpp 
Log Message:
Fix walking in IHNM. It appeared that BG mask wasn't flipped upside down
when everything else is :).


Index: image.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/image.cpp,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -d -r1.26 -r1.27
--- image.cpp	13 Aug 2005 01:05:59 -0000	1.26
+++ image.cpp	17 Oct 2005 14:20:18 -0000	1.27
@@ -47,7 +47,7 @@
 }
 
 int SagaEngine::decodeBGImage(const byte *image_data, size_t image_size,
-					byte **output_buf, size_t *output_buf_len, int *w, int *h) {
+				  byte **output_buf, size_t *output_buf_len, int *w, int *h, bool flip) {
 	ImageHeader hdr;
 	int modex_height;
 	const byte *RLE_data_ptr;
@@ -90,7 +90,7 @@
 	unbankBGImage(out_buf, decode_buf, hdr.width, hdr.height);
 
 	// For some reason bg images in IHNM are upside down
-	if (getGameType() == GType_IHNM) {
+	if (getGameType() == GType_IHNM && !flip) {
 		flipImage(out_buf, hdr.width, hdr.height);
 	}
 

Index: saga.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/saga.h,v
retrieving revision 1.134
retrieving revision 1.135
diff -u -d -r1.134 -r1.135
--- saga.h	17 Oct 2005 03:28:21 -0000	1.134
+++ saga.h	17 Oct 2005 14:20:18 -0000	1.135
@@ -632,7 +632,7 @@
 
 public:
 	int decodeBGImage(const byte *image_data, size_t image_size,
-						byte **output_buf, size_t *output_buf_len, int *w, int *h);
+			  byte **output_buf, size_t *output_buf_len, int *w, int *h, bool flip = false);
 	const byte *getImagePal(const byte *image_data, size_t image_size);
 	void loadStrings(StringsTable &stringsTable, const byte *stringsPointer, size_t stringsLength);
 

Index: scene.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/saga/scene.cpp,v
retrieving revision 1.155
retrieving revision 1.156
diff -u -d -r1.155 -r1.156
--- scene.cpp	11 Oct 2005 17:39:31 -0000	1.155
+++ scene.cpp	17 Oct 2005 14:20:18 -0000	1.156
@@ -1040,7 +1040,7 @@
 			_bgMask.res_len = resourceDataLength;
 			_bgMask.loaded = 1;
 			_vm->decodeBGImage(_bgMask.res_buf, _bgMask.res_len, &_bgMask.buf,
-							&_bgMask.buf_len, &_bgMask.w, &_bgMask.h);
+							   &_bgMask.buf_len, &_bgMask.w, &_bgMask.h, true);
 
 			// At least in ITE the mask needs to be clipped.
 





More information about the Scummvm-git-logs mailing list