[Scummvm-git-logs] scummvm master -> 71fd176f053520e34541d6c8be72214d9afb94ef

dreammaster dreammaster at scummvm.org
Sun Sep 11 17:51:25 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:
71fd176f05 IMAGE: Compilation fixes for Indeo codecs


Commit: 71fd176f053520e34541d6c8be72214d9afb94ef
    https://github.com/scummvm/scummvm/commit/71fd176f053520e34541d6c8be72214d9afb94ef
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2016-09-11T11:51:16-04:00

Commit Message:
IMAGE: Compilation fixes for Indeo codecs

Changed paths:
    image/codecs/indeo/indeo.cpp
    image/codecs/indeo/indeo.h
    image/codecs/indeo/indeo_dsp.cpp
    image/codecs/indeo/vlc.cpp



diff --git a/image/codecs/indeo/indeo.cpp b/image/codecs/indeo/indeo.cpp
index adc7229..c0950f7 100644
--- a/image/codecs/indeo/indeo.cpp
+++ b/image/codecs/indeo/indeo.cpp
@@ -1156,7 +1156,7 @@ int IndeoDecoderBase::decodeBlocks(GetBits *_gb, IVIBandDesc *band, IVITile *til
 			}
 
 			if (cbp & 1) { // block coded ?
-				ret = ivi_decode_coded_blocks(_gb, band, mcWithDeltaFunc,
+				ret = decodeCodedBlocks(_gb, band, mcWithDeltaFunc,
 											  mcAvgWithDeltaFunc,
 											  mvX, mvY, mvX2, mvY2,
 											  &prevDc, isIntra,
@@ -1169,7 +1169,7 @@ int IndeoDecoderBase::decodeBlocks(GetBits *_gb, IVIBandDesc *band, IVITile *til
 				// for intra blocks apply the dc slant transform
 				// for inter - perform the motion compensation without delta
 				if (isIntra) {
-					ret = ivi_dc_transform(band, &prevDc, bufOffs, blkSize);
+					ret = iviDcTransform(band, &prevDc, bufOffs, blkSize);
 					if (ret < 0)
 						return ret;
 				} else {
@@ -1229,9 +1229,9 @@ int IndeoDecoderBase::iviMc(IVIBandDesc *band, IviMCFunc mc, IviMCAvgFunc mcAvg,
 	return 0;
 }
 
-int IndeoDecoderBase::ivi_decode_coded_blocks(GetBits *gb, IVIBandDesc *band,
+int IndeoDecoderBase::decodeCodedBlocks(GetBits *gb, IVIBandDesc *band,
 		IviMCFunc mc, IviMCAvgFunc mcAvg, int mvX, int mvY,
-		int mvX2, int mvY2, int *prevDc, int isIntra,
+		int mvX2, int mvY2, int32 *prevDc, int isIntra,
 		int mcType, int mcType2, uint32 quant, int offs) {
 	const uint16 *baseTab = isIntra ? band->_intraBase : band->_interBase;
 	RVMapDesc *rvmap = band->_rvMap;
@@ -1326,7 +1326,7 @@ int IndeoDecoderBase::ivi_decode_coded_blocks(GetBits *gb, IVIBandDesc *band,
 	return 0;
 }
 
-int IndeoDecoderBase::ivi_dc_transform(IVIBandDesc *band, int *prevDc,
+int IndeoDecoderBase::iviDcTransform(IVIBandDesc *band, int32 *prevDc,
 		int bufOffs, int blkSize) {
 	int bufSize = band->_pitch * band->_aHeight - bufOffs;
 	int minSize = (blkSize - 1) * band->_pitch + blkSize;
@@ -1334,9 +1334,7 @@ int IndeoDecoderBase::ivi_dc_transform(IVIBandDesc *band, int *prevDc,
 	if (minSize > bufSize)
 		return -1;
 
-	band->_dcTransform(prevDc, band->_buf + bufOffs,
-		band->_pitch, blkSize);
-
+	band->_dcTransform(prevDc, band->_buf + bufOffs, band->_pitch, blkSize);
 	return 0;
 }
 
diff --git a/image/codecs/indeo/indeo.h b/image/codecs/indeo/indeo.h
index 3b0b185..b4584a3 100644
--- a/image/codecs/indeo/indeo.h
+++ b/image/codecs/indeo/indeo.h
@@ -508,12 +508,12 @@ private:
 	int iviMc(IVIBandDesc *band, IviMCFunc mc, IviMCAvgFunc mcAvg,
 		int offs, int mvX, int mvY, int mvX2, int mvY2, int mcType, int mcType2);
 
-	int ivi_decode_coded_blocks(GetBits *gb, IVIBandDesc *band,
+	int decodeCodedBlocks(GetBits *gb, IVIBandDesc *band,
 		IviMCFunc mc, IviMCAvgFunc mcAvg, int mvX, int mvY,
-		int mvX2, int mvY2, int *prevDc, int isIntra,
+		int mvX2, int mvY2, int32 *prevDc, int isIntra,
 		int mcType, int mcType2, uint32 quant, int offs);
 
-	int ivi_dc_transform(IVIBandDesc *band, int *prevDc, int bufOffs,
+	int iviDcTransform(IVIBandDesc *band, int32 *prevDc, int bufOffs,
 		int blkSize);
 protected:
 	IVI45DecContext _ctx;
diff --git a/image/codecs/indeo/indeo_dsp.cpp b/image/codecs/indeo/indeo_dsp.cpp
index b095151..95ce3f3 100644
--- a/image/codecs/indeo/indeo_dsp.cpp
+++ b/image/codecs/indeo/indeo_dsp.cpp
@@ -73,7 +73,7 @@ namespace Indeo {
 
 void IndeoDSP::ffIviInverseHaar8x8(const int32 *in, int16 *out, uint32 pitch,
 							 const uint8 *flags) {
-	int tmp[64];
+	int32 tmp[64];
 	int t0, t1, t2, t3, t4, t5, t6, t7, t8;
 
 	// apply the InvHaar8 to all columns
@@ -107,8 +107,8 @@ void IndeoDSP::ffIviInverseHaar8x8(const int32 *in, int16 *out, uint32 pitch,
 #define COMPENSATE(x) (x)
 	src = tmp;
 	for (int i = 0; i < 8; i++) {
-		if (   !src[0] && !src[1] && !src[2] && !src[3]
-			&& !src[4] && !src[5] && !src[6] && !src[7]) {
+		if (!src[0] && !src[1] && !src[2] && !src[3] &&
+				!src[4] && !src[5] && !src[6] && !src[7]) {
 			memset(out, 0, 8 * sizeof(out[0]));
 		} else {
 			INV_HAAR8(src[0], src[1], src[2], src[3],
@@ -176,7 +176,7 @@ void IndeoDSP::ffIviColHaar8(const int32 *in, int16 *out, uint32 pitch,
 
 void IndeoDSP::ffIviInverseHaar4x4(const int32 *in, int16 *out, uint32 pitch,
 							 const uint8 *flags) {
-	int tmp[16];
+	int32 tmp[16];
 	int t0, t1, t2, t3, t4;
 
 	// apply the InvHaar4 to all columns
@@ -322,7 +322,7 @@ void IndeoDSP::ffIviDcHaar2d(const int32 *in, int16 *out, uint32 pitch,
 	d4 = COMPENSATE(t4);}
 
 void IndeoDSP::ffIviInverseSlant8x8(const int32 *in, int16 *out, uint32 pitch, const uint8 *flags) {
-	int tmp[64];
+	int32 tmp[64];
 	int t0, t1, t2, t3, t4, t5, t6, t7, t8;
 
 #define COMPENSATE(x) (x)
@@ -359,7 +359,7 @@ void IndeoDSP::ffIviInverseSlant8x8(const int32 *in, int16 *out, uint32 pitch, c
 }
 
 void IndeoDSP::ffIviInverseSlant4x4(const int32 *in, int16 *out, uint32 pitch, const uint8 *flags) {
-	int tmp[16];
+	int32 tmp[16];
 	int t0, t1, t2, t3, t4;
 
 #define COMPENSATE(x) (x)
diff --git a/image/codecs/indeo/vlc.cpp b/image/codecs/indeo/vlc.cpp
index 5b9e96c..baf3984 100644
--- a/image/codecs/indeo/vlc.cpp
+++ b/image/codecs/indeo/vlc.cpp
@@ -155,7 +155,7 @@ int VLC::init_vlc(int nbBits, int nbCodes, const void *p_bits, int bitsWrap,
 	vlc = this;
 	vlc->_bits = nbBits;
 	if (flags & INIT_VLC_USE_NEW_STATIC) {
-		assert((nbCodes + 1) <= FF_ARRAY_ELEMS(localbuf));
+		assert((nbCodes + 1) <= (int)FF_ARRAY_ELEMS(localbuf));
 		buf = localbuf;
 		localvlc = *this;
 		vlc = &localvlc;





More information about the Scummvm-git-logs mailing list