[Scummvm-cvs-logs] CVS: scummvm/common/scaler hq2x.cpp,1.14,1.15 hq3x.cpp,1.12,1.13
Max Horn
fingolfin at users.sourceforge.net
Mon May 9 14:23:44 CEST 2005
Update of /cvsroot/scummvm/scummvm/common/scaler
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31171/common/scaler
Modified Files:
hq2x.cpp hq3x.cpp
Log Message:
Patch #1181544 (AmigaOS 4 changes)
Index: hq2x.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/common/scaler/hq2x.cpp,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -d -r1.14 -r1.15
--- hq2x.cpp 8 May 2005 21:49:32 -0000 1.14
+++ hq2x.cpp 9 May 2005 21:21:18 -0000 1.15
@@ -42,6 +42,20 @@
#else
#ifdef HAS_ALTIVEC
+
+#ifdef __amigaos4__
+#include <proto/exec.h>
+#include <altivec.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() {
@@ -54,6 +68,7 @@
return false;
}
#endif
+#endif
#define PIXEL00_0 *(q) = w5;
#define PIXEL00_10 *(q) = interpolate16_2<bitFormat,3,1>(w5, w1);
Index: hq3x.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/common/scaler/hq3x.cpp,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -d -r1.12 -r1.13
--- hq3x.cpp 8 May 2005 21:49:40 -0000 1.12
+++ hq3x.cpp 9 May 2005 21:21:19 -0000 1.13
@@ -42,6 +42,19 @@
#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() {
@@ -54,6 +67,7 @@
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);
More information about the Scummvm-git-logs
mailing list