[Scummvm-cvs-logs] scummvm master -> 16a3f9923059c6328d0f34a5d2582fdf2885b784

sev- sev at scummvm.org
Fri Aug 19 22:12:40 CEST 2016


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
16a3f99230 FULLPIPE: Fix Bitmap flipping code. Thanks to wanwan


Commit: 16a3f9923059c6328d0f34a5d2582fdf2885b784
    https://github.com/scummvm/scummvm/commit/16a3f9923059c6328d0f34a5d2582fdf2885b784
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2016-08-19T22:12:31+02:00

Commit Message:
FULLPIPE: Fix Bitmap flipping code. Thanks to wanwan

Changed paths:
    engines/fullpipe/gfx.cpp



diff --git a/engines/fullpipe/gfx.cpp b/engines/fullpipe/gfx.cpp
index dd8d8b2..2da97f4 100644
--- a/engines/fullpipe/gfx.cpp
+++ b/engines/fullpipe/gfx.cpp
@@ -1122,12 +1122,16 @@ void Bitmap::copier(uint32 *dest, byte *src, int len, int32 *palette, bool cb05_
 }
 
 Bitmap *Bitmap::reverseImage(bool flip) {
-	if (flip)
-		_flipping = Graphics::FLIP_H;
-	else
-		_flipping = Graphics::FLIP_NONE;
+	Bitmap *b = new Bitmap(this);
 
-	return this;
+	if (flip) {
+		if (b->_flipping == Graphics::FLIP_NONE)
+			b->_flipping = Graphics::FLIP_H;
+		else
+			b->_flipping = Graphics::FLIP_NONE;
+	}
+
+	return b;
 }
 
 Bitmap *Bitmap::flipVertical() {






More information about the Scummvm-git-logs mailing list