diff options
-rw-r--r-- | common/scaler.cpp | 2 | ||||
-rw-r--r-- | common/scaler/2xsai.cpp | 6 | ||||
-rw-r--r-- | common/scaler/hq2x.cpp | 2 | ||||
-rw-r--r-- | common/scaler/hq3x.cpp | 2 | ||||
-rw-r--r-- | common/scaler/intern.h | 17 |
5 files changed, 9 insertions, 20 deletions
diff --git a/common/scaler.cpp b/common/scaler.cpp index d8522440af..00f784fd0a 100644 --- a/common/scaler.cpp +++ b/common/scaler.cpp @@ -233,7 +233,7 @@ void AdvMame3x(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPi } template<int bitFormat> -void TV2x(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, +void TV2xTemplate(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { const uint32 nextlineSrc = srcPitch / sizeof(uint16); const uint16 *p = (const uint16 *)srcPtr; diff --git a/common/scaler/2xsai.cpp b/common/scaler/2xsai.cpp index 1c99168e63..dd5cf23c4a 100644 --- a/common/scaler/2xsai.cpp +++ b/common/scaler/2xsai.cpp @@ -47,7 +47,7 @@ static inline int GetResult(uint32 A, uint32 B, uint32 C, uint32 D) { #define Q_INTERPOLATE Q_INTERPOLATE<bitFormat> template<int bitFormat> -void Super2xSaI(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { +void Super2xSaITemplate(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { const uint16 *bP; uint16 *dP; const uint32 nextlineSrc = srcPitch >> 1; @@ -156,7 +156,7 @@ void Super2xSaI(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstP MAKE_WRAPPER(Super2xSaI) template<int bitFormat> -void SuperEagle(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { +void SuperEagleTemplate(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { const uint16 *bP; uint16 *dP; const uint32 nextlineSrc = srcPitch >> 1; @@ -267,7 +267,7 @@ void SuperEagle(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstP MAKE_WRAPPER(SuperEagle) template<int bitFormat> -void _2xSaI(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { +void _2xSaITemplate(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { const uint16 *bP; uint16 *dP; const uint32 nextlineSrc = srcPitch >> 1; diff --git a/common/scaler/hq2x.cpp b/common/scaler/hq2x.cpp index cd461f7be9..462729804c 100644 --- a/common/scaler/hq2x.cpp +++ b/common/scaler/hq2x.cpp @@ -82,7 +82,7 @@ * Adapted for ScummVM to 16 bit output and optimized by Max Horn. */ template<int bitFormat> -void HQ2x(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { +void HQ2xTemplate(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { register int w1, w2, w3, w4, w5, w6, w7, w8, w9; const uint32 nextlineSrc = srcPitch / sizeof(uint16); diff --git a/common/scaler/hq3x.cpp b/common/scaler/hq3x.cpp index 46ccc2e327..97d8f02e62 100644 --- a/common/scaler/hq3x.cpp +++ b/common/scaler/hq3x.cpp @@ -85,7 +85,7 @@ * Adapted for ScummVM to 16 bit output and optimized by Max Horn. */ template<int bitFormat> -void HQ3x(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { +void HQ3xTemplate(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { register int w1, w2, w3, w4, w5, w6, w7, w8, w9; const uint32 nextlineSrc = srcPitch / sizeof(uint16); diff --git a/common/scaler/intern.h b/common/scaler/intern.h index e0076d93a0..da82ab9b82 100644 --- a/common/scaler/intern.h +++ b/common/scaler/intern.h @@ -35,9 +35,6 @@ // #define USE_ALTIVEC 0 -// MSVC6 chokes on all but the most simplistic template usage. -#ifndef MSVC6_COMPAT - template<int bitFormat> struct ColorMasks { }; @@ -170,20 +167,12 @@ extern int RGBtoYUV[65536]; #define MAKE_WRAPPER(FUNC) \ void FUNC(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { \ if (gBitFormat == 565) \ - FUNC<565>(srcPtr, srcPitch, dstPtr, dstPitch, width, height); \ + FUNC ## Template<565>(srcPtr, srcPitch, dstPtr, dstPitch, width, height); \ else \ - FUNC<555>(srcPtr, srcPitch, dstPtr, dstPitch, width, height); \ - } - -#else // MSVC6_COMPAT is defined - -#define MAKE_WRAPPER(FUNC) \ - void FUNC(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) { \ - return; \ + FUNC ## Template<555>(srcPtr, srcPitch, dstPtr, dstPitch, width, height); \ } -#endif - +/** Specifies the currently active 16bit pixel format, 555 or 565. */ extern int gBitFormat; #endif |