[Scummvm-cvs-logs] scummvm master -> fcdbd2c066bbcabe787a2ab8cd05fc49dfcaca3a

sev- sev at scummvm.org
Sun May 1 16:51:45 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:
fcdbd2c066 SCUMM HE: Further work on T14 codec


Commit: fcdbd2c066bbcabe787a2ab8cd05fc49dfcaca3a
    https://github.com/scummvm/scummvm/commit/fcdbd2c066bbcabe787a2ab8cd05fc49dfcaca3a
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2016-05-01T16:51:08+02:00

Commit Message:
SCUMM HE: Further work on T14 codec

Changed paths:
    engines/scumm/he/moonbase/moonbase.cpp
    engines/scumm/he/moonbase/moonbase.h
    engines/scumm/he/wiz_he.cpp
    engines/scumm/he/wiz_he.h



diff --git a/engines/scumm/he/moonbase/moonbase.cpp b/engines/scumm/he/moonbase/moonbase.cpp
index 1319f56..9acc7a1 100644
--- a/engines/scumm/he/moonbase/moonbase.cpp
+++ b/engines/scumm/he/moonbase/moonbase.cpp
@@ -37,4 +37,8 @@ void Moonbase::renderFOW() {
 	warning("STUB: renderFOW()");
 }
 
+void Moonbase::blitT14WizImage(uint8 *dst, int dstw, int dsth, int dstPitch, const Common::Rect *clipBox,
+		 uint8 *wizd, int srcx, int srcy, int rawROP, int paramROP) {
+}
+
 } // End of namespace Scumm
diff --git a/engines/scumm/he/moonbase/moonbase.h b/engines/scumm/he/moonbase/moonbase.h
index 0fa6b42..7ff2f17 100644
--- a/engines/scumm/he/moonbase/moonbase.h
+++ b/engines/scumm/he/moonbase/moonbase.h
@@ -34,6 +34,9 @@ public:
 
 	void renderFOW();
 
+	void blitT14WizImage(uint8 *dst, int dstw, int dsth, int dstPitch, const Common::Rect *clipBox,
+			 uint8 *wizd, int srcx, int srcy, int rawROP, int paramROP);
+
 public:
 	int _fowSentinelImage;
 	int _fowSentinelState;
diff --git a/engines/scumm/he/wiz_he.cpp b/engines/scumm/he/wiz_he.cpp
index 60eb859..a8baae8 100644
--- a/engines/scumm/he/wiz_he.cpp
+++ b/engines/scumm/he/wiz_he.cpp
@@ -1635,7 +1635,7 @@ void Wiz::drawWizImageEx(uint8 *dst, uint8 *dataPtr, uint8 *maskPtr, int dstPitc
 		copy16BitWizImage(dst, wizd, dstPitch, dstType, dstw, dsth, srcx, srcy, srcw, srch, rect, flags, xmapPtr);
 		break;
 	case 9:
-		copyT14WizImage(dst, wizd, dstPitch, dstType, dstw, dsth, srcx, srcy, rect, conditionBits);
+		copy555WizImage(dst, wizd, dstPitch, dstType, dstw, dsth, srcx, srcy, rect, conditionBits);
 		break;
 #endif
 	default:
@@ -1764,11 +1764,11 @@ void Wiz::copyCompositeWizImage(uint8 *dst, uint8 *wizPtr, uint8 *compositeInfoB
 	}
 }
 
-void Wiz::copyT14WizImage(uint8 *dst, uint8 *wizd, int dstPitch, int dstType,
+void Wiz::copy555WizImage(uint8 *dst, uint8 *wizd, int dstPitch, int dstType,
 		int dstw, int dsth, int srcx, int srcy, const Common::Rect *clipBox, uint16 conditionBits) {
 
 	int rawROP = conditionBits & kWMSBRopMask;
-	int nROPParam = (conditionBits & kWMSBReservedBits) >> kWMSBRopParamRShift;
+	int paramROP = (conditionBits & kWMSBReservedBits) >> kWMSBRopParamRShift;
 
 	switch (rawROP) {
 	default:
@@ -1801,7 +1801,17 @@ void Wiz::copyT14WizImage(uint8 *dst, uint8 *wizd, int dstPitch, int dstType,
 		break;
 	}
 
-	warning("T14: params %d", nROPParam);
+
+	uint32 compID = READ_LE_UINT32(wizd);
+
+	if (compID == 0x12340102) {
+		_vm->_moonbase->blitT14WizImage(dst, dstw, dsth, dstPitch, clipBox, wizd, srcx, srcy, rawROP, paramROP);
+	} else if (compID == 0x12340802) {
+		warning("Distorion codec");
+	} else if (compID == 0x12340902) {
+		error("Unsupported Distortion");
+	}
+
 }
 
 #endif
diff --git a/engines/scumm/he/wiz_he.h b/engines/scumm/he/wiz_he.h
index fee67a7..fb83884 100644
--- a/engines/scumm/he/wiz_he.h
+++ b/engines/scumm/he/wiz_he.h
@@ -250,7 +250,7 @@ public:
 	void copyCompositeWizImage(uint8 *dst, uint8 *wizPtr, uint8 *wizd, uint8 *maskPtr, int dstPitch, int dstType,
 		int dstw, int dsth, int srcx, int srcy, int srcw, int srch, int state, const Common::Rect *clipBox,
 		int flags, const uint8 *palPtr, int transColor, uint8 bitDepth, const uint8 *xmapPtr, uint16 conditionBits);
-	void copyT14WizImage(uint8 *dst, uint8 *wizd, int dstPitch, int dstType,
+	void copy555WizImage(uint8 *dst, uint8 *wizd, int dstPitch, int dstType,
 			int dstw, int dsth, int srcx, int srcy, const Common::Rect *clipBox, uint16 conditionBits);
 #endif
 






More information about the Scummvm-git-logs mailing list