aboutsummaryrefslogtreecommitdiff
path: root/graphics/scaler/hq3x.cpp
diff options
context:
space:
mode:
authorMax Horn2006-04-17 08:38:26 +0000
committerMax Horn2006-04-17 08:38:26 +0000
commitde250812e5e2a15fc3a1dddc9faae09f1c2df6d6 (patch)
treea612e6479a9a3e78e43b68f88d23cbf9f725dbdb /graphics/scaler/hq3x.cpp
parent092893a16d021a2391a3adfbb07db5f8bf9ee073 (diff)
downloadscummvm-rg350-de250812e5e2a15fc3a1dddc9faae09f1c2df6d6.tar.gz
scummvm-rg350-de250812e5e2a15fc3a1dddc9faae09f1c2df6d6.tar.bz2
scummvm-rg350-de250812e5e2a15fc3a1dddc9faae09f1c2df6d6.zip
Removed my Altivec version of the hqx blitters, since it (a) didn't work with newer GCC versions, (b) speed was improved on some systems, but actually slower on others, and (c) even on my old 400 Mhz G4 hqx is fast enough w/o it
svn-id: r21961
Diffstat (limited to 'graphics/scaler/hq3x.cpp')
-rw-r--r--graphics/scaler/hq3x.cpp54
1 files changed, 0 insertions, 54 deletions
diff --git a/graphics/scaler/hq3x.cpp b/graphics/scaler/hq3x.cpp
index 64bd17834d..2d0f50bd76 100644
--- a/graphics/scaler/hq3x.cpp
+++ b/graphics/scaler/hq3x.cpp
@@ -43,34 +43,6 @@ void HQ3x(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch,
#else
-#ifdef HAS_ALTIVEC
-
-#ifdef __amigaos4__
-#include <proto/exec.h>
-static bool isAltiVecAvailable() {
- uint32 vecUnit;
- IExec->GetCPUInfo(GCIT_VectorUnit, &vecUnit, TAG_DONE);
- if (vecUnit == VECTORTYPE_NONE)
- return false;
- else
- return true;
-}
-#else
-
-#include <sys/sysctl.h>
-
-static bool isAltiVecAvailable() {
- int selectors[2] = { CTL_HW, HW_VECTORUNIT };
- int hasVectorUnit = 0;
- size_t length = sizeof(hasVectorUnit);
- int error = sysctl(selectors, 2, &hasVectorUnit, &length, NULL, 0);
- if ( 0 == error )
- return hasVectorUnit != 0;
- return false;
-}
-#endif
-#endif
-
#define PIXEL00_1M *(q) = interpolate16_2<bitFormat,3,1>(w5, w1);
#define PIXEL00_1U *(q) = interpolate16_2<bitFormat,3,1>(w5, w2);
#define PIXEL00_1L *(q) = interpolate16_2<bitFormat,3,1>(w5, w4);
@@ -141,33 +113,7 @@ void HQ3x_555(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPit
#undef bitFormat
-#ifdef HAS_ALTIVEC
- #define USE_ALTIVEC 1
-
- #define bitFormat 565
- void HQ3x_565_Altivec(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) {
- #include "graphics/scaler/hq3x.h"
- }
- #undef bitFormat
-
- #define bitFormat 555
- void HQ3x_555_Altivec(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) {
- #include "graphics/scaler/hq3x.h"
- }
- #undef bitFormat
-#endif
-
void HQ3x(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, uint32 dstPitch, int width, int height) {
-#ifdef HAS_ALTIVEC
- if (isAltiVecAvailable()) {
- if (gBitFormat == 565)
- HQ3x_565_Altivec(srcPtr, srcPitch, dstPtr, dstPitch, width, height);
- else
- HQ3x_555_Altivec(srcPtr, srcPitch, dstPtr, dstPitch, width, height);
- return;
- }
-#endif
-
if (gBitFormat == 565)
HQ3x_565(srcPtr, srcPitch, dstPtr, dstPitch, width, height);
else