Permalink
Browse files

Revert the rest of the karaokeplayer commits. fixes xcode builds

This reverts commit 5684e8e and 33a0666
  • Loading branch information...
1 parent bae5701 commit dc0514f09d52f414e33d369dc0b75c3215a64873 Lars Op den Kamp committed Dec 17, 2011
@@ -7,7 +7,6 @@
objects = {
/* Begin PBXBuildFile section */
- 1809F6F0149C924B00960880 /* karaokevideobackground.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1809F6EE149C924B00960880 /* karaokevideobackground.cpp */; };
1830216013B8E35300770920 /* controledit.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1830215F13B8E35300770920 /* controledit.cpp */; };
18404DFB1396C43B00863BBA /* Slingbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 18404DF91396C43B00863BBA /* Slingbox.cpp */; };
18404DFD1396C44F00863BBA /* SlingboxLib.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 18404DFC1396C44F00863BBA /* SlingboxLib.a */; };
@@ -948,8 +947,6 @@
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
- 1809F6EE149C924B00960880 /* karaokevideobackground.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = karaokevideobackground.cpp; sourceTree = "<group>"; };
- 1809F6EF149C924B00960880 /* karaokevideobackground.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = karaokevideobackground.h; sourceTree = "<group>"; };
1830215F13B8E35300770920 /* controledit.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = controledit.cpp; sourceTree = "<group>"; };
18404DF91396C43B00863BBA /* Slingbox.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Slingbox.cpp; sourceTree = "<group>"; };
18404DFA1396C43B00863BBA /* Slingbox.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Slingbox.h; sourceTree = "<group>"; };
@@ -4751,8 +4748,6 @@
F56C75EE131EC153000AD0F6 /* karaokelyricstextlrc.h */,
F56C75EF131EC153000AD0F6 /* karaokelyricstextustar.cpp */,
F56C75F0131EC153000AD0F6 /* karaokelyricstextustar.h */,
- 1809F6EE149C924B00960880 /* karaokevideobackground.cpp */,
- 1809F6EF149C924B00960880 /* karaokevideobackground.h */,
F56C75F1131EC153000AD0F6 /* karaokewindowbackground.cpp */,
F56C75F2131EC153000AD0F6 /* karaokewindowbackground.h */,
);
@@ -6939,7 +6934,6 @@
F5E113AD1435882400175026 /* pyrendercapture.cpp in Sources */,
DF673A251443769300A5A509 /* FileUPnP.cpp in Sources */,
F5BD033A148D4923001B5583 /* CryptThreading.cpp in Sources */,
- 1809F6F0149C924B00960880 /* karaokevideobackground.cpp in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -7,7 +7,6 @@
objects = {
/* Begin PBXBuildFile section */
- 1809F6FD149C927700960880 /* karaokevideobackground.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1809F6FB149C927700960880 /* karaokevideobackground.cpp */; };
1830219E13B8E37300770920 /* controledit.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1830219D13B8E37300770920 /* controledit.cpp */; };
18404DD31396C3D200863BBA /* SlingboxLib.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 18404DD21396C3D200863BBA /* SlingboxLib.a */; };
18404DD61396C3F300863BBA /* Slingbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 18404DD41396C3F300863BBA /* Slingbox.cpp */; };
@@ -948,8 +947,6 @@
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
- 1809F6FB149C927700960880 /* karaokevideobackground.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = karaokevideobackground.cpp; sourceTree = "<group>"; };
- 1809F6FC149C927700960880 /* karaokevideobackground.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = karaokevideobackground.h; sourceTree = "<group>"; };
1830219D13B8E37300770920 /* controledit.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = controledit.cpp; sourceTree = "<group>"; };
18404DD21396C3D200863BBA /* SlingboxLib.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = SlingboxLib.a; path = lib/SlingboxLib/SlingboxLib.a; sourceTree = "<group>"; };
18404DD41396C3F300863BBA /* Slingbox.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Slingbox.cpp; sourceTree = "<group>"; };
@@ -5110,8 +5107,6 @@
F56C85D1131F42EA000AD0F6 /* karaokelyricstextlrc.h */,
F56C85D2131F42EA000AD0F6 /* karaokelyricstextustar.cpp */,
F56C85D3131F42EA000AD0F6 /* karaokelyricstextustar.h */,
- 1809F6FB149C927700960880 /* karaokevideobackground.cpp */,
- 1809F6FC149C927700960880 /* karaokevideobackground.h */,
F56C85D4131F42EA000AD0F6 /* karaokewindowbackground.cpp */,
F56C85D5131F42EA000AD0F6 /* karaokewindowbackground.h */,
);
@@ -6954,7 +6949,6 @@
F5E112EC143577A000175026 /* Peripherals.cpp in Sources */,
DF6739E21443765F00A5A509 /* FileUPnP.cpp in Sources */,
F5BD034F148D496A001B5583 /* CryptThreading.cpp in Sources */,
- 1809F6FD149C927700960880 /* karaokevideobackground.cpp in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -38,8 +38,6 @@
/* End PBXAggregateTarget section */
/* Begin PBXBuildFile section */
- 1809F6E0149C91E000960880 /* karaokevideobackground.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1809F6DE149C91E000960880 /* karaokevideobackground.cpp */; };
- 1809F6E1149C91E000960880 /* karaokevideobackground.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1809F6DE149C91E000960880 /* karaokevideobackground.cpp */; };
1830212813B8E2DC00770920 /* controledit.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1830212713B8E2DC00770920 /* controledit.cpp */; };
1830212913B8E2DC00770920 /* controledit.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1830212713B8E2DC00770920 /* controledit.cpp */; };
183C454D130C4D55006AA317 /* xbmcvfsmodule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 189047D11301DEAB00C11012 /* xbmcvfsmodule.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
@@ -1941,8 +1939,6 @@
/* Begin PBXFileReference section */
09AB6884FE841BABC02AAC07 /* CoreFoundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreFoundation.framework; path = ../../../System/Library/Frameworks/CoreFoundation.framework; sourceTree = SDKROOT; };
- 1809F6DE149C91E000960880 /* karaokevideobackground.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = karaokevideobackground.cpp; sourceTree = "<group>"; };
- 1809F6DF149C91E000960880 /* karaokevideobackground.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = karaokevideobackground.h; sourceTree = "<group>"; };
1830212713B8E2DC00770920 /* controledit.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = controledit.cpp; sourceTree = "<group>"; };
18308CB41303370800AA309E /* stat_utf8.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = stat_utf8.h; sourceTree = "<group>"; };
18308CB51303370800AA309E /* stdio_utf8.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = stdio_utf8.h; sourceTree = "<group>"; };
@@ -4618,8 +4614,6 @@
F54C51E00F1E787700D46E3C /* karaokelyricstextlrc.h */,
7CDAEA7B1001CD6E0040B25F /* karaokelyricstextustar.cpp */,
7CDAEA7C1001CD6E0040B25F /* karaokelyricstextustar.h */,
- 1809F6DE149C91E000960880 /* karaokevideobackground.cpp */,
- 1809F6DF149C91E000960880 /* karaokevideobackground.h */,
F56A084A0F4A18FB003F9F87 /* karaokewindowbackground.cpp */,
F56A08490F4A18FB003F9F87 /* karaokewindowbackground.h */,
);
@@ -8049,7 +8043,6 @@
DF85BAB51443669A000686BE /* FileUPnP.cpp in Sources */,
DF673AA51443819600A5A509 /* AddonManager.cpp in Sources */,
F5BD02F6148D3A7E001B5583 /* CryptThreading.cpp in Sources */,
- 1809F6E0149C91E000960880 /* karaokevideobackground.cpp in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -8970,7 +8963,6 @@
F54BCC601439345300F86B0F /* HotKeyController.m in Sources */,
DF85BAB61443669A000686BE /* FileUPnP.cpp in Sources */,
F5BD02F7148D3A7E001B5583 /* CryptThreading.cpp in Sources */,
- 1809F6E1149C91E000960880 /* karaokevideobackground.cpp in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -52,13 +52,193 @@
# include <stdbool.h>
#endif
+/*****************************************************************************/
+#if OPT_MODE == 1
+
#ifdef LITTLE_ENDIAN
#define iman_ 0
#else
#define iman_ 1
#endif
#define _double2fixmagic 68719476736.0 * 1.5
+#if defined(__GNUC__) && defined(__i386__)
+static inline int32 imuldiv8(int32 a, int32 b)
+{
+ int32 result;
+ __asm__("movl %1, %%eax\n\t"
+ "movl %2, %%edx\n\t"
+ "imull %%edx\n\t"
+ "shr $8, %%eax\n\t"
+ "shl $24, %%edx\n\t"
+ "or %%edx, %%eax\n\t"
+ "movl %%eax, %0\n\t"
+ : "=g"(result)
+ : "g"(a), "g"(b)
+ : "eax", "edx");
+ return result;
+}
+
+static inline int32 imuldiv16(int32 a, int32 b)
+{
+ int32 result;
+ __asm__("movl %1, %%eax\n\t"
+ "movl %2, %%edx\n\t"
+ "imull %%edx\n\t"
+ "shr $16, %%eax\n\t"
+ "shl $16, %%edx\n\t"
+ "or %%edx, %%eax\n\t"
+ "movl %%eax, %0\n\t"
+ : "=g"(result)
+ : "g"(a), "g"(b)
+ : "eax", "edx");
+ return result;
+}
+
+static inline int32 imuldiv24(int32 a, int32 b)
+{
+ int32 result;
+ __asm__("movl %1, %%eax\n\t"
+ "movl %2, %%edx\n\t"
+ "imull %%edx\n\t"
+ "shr $24, %%eax\n\t"
+ "shl $8, %%edx\n\t"
+ "or %%edx, %%eax\n\t"
+ "movl %%eax, %0\n\t"
+ : "=g"(result)
+ : "g"(a), "g"(b)
+ : "eax", "edx");
+ return result;
+}
+
+static inline int32 imuldiv28(int32 a, int32 b)
+{
+ int32 result;
+ __asm__("movl %1, %%eax\n\t"
+ "movl %2, %%edx\n\t"
+ "imull %%edx\n\t"
+ "shr $28, %%eax\n\t"
+ "shl $4, %%edx\n\t"
+ "or %%edx, %%eax\n\t"
+ "movl %%eax, %0\n\t"
+ : "=g"(result)
+ : "g"(a), "g"(b)
+ : "eax", "edx");
+ return result;
+}
+
+#elif _MSC_VER
+inline int32 imuldiv8(int32 a, int32 b) {
+ _asm {
+ mov eax, a
+ mov edx, b
+ imul edx
+ shr eax, 8
+ shl edx, 24
+ or eax, edx
+ }
+}
+
+inline int32 imuldiv16(int32 a, int32 b) {
+ _asm {
+ mov eax, a
+ mov edx, b
+ imul edx
+ shr eax, 16
+ shl edx, 16
+ or eax, edx
+ }
+}
+
+inline int32 imuldiv24(int32 a, int32 b) {
+ _asm {
+ mov eax, a
+ mov edx, b
+ imul edx
+ shr eax, 24
+ shl edx, 8
+ or eax, edx
+ }
+}
+
+inline int32 imuldiv28(int32 a, int32 b) {
+ _asm {
+ mov eax, a
+ mov edx, b
+ imul edx
+ shr eax, 28
+ shl edx, 4
+ or eax, edx
+ }
+}
+
+#elif defined(__GNUC__) && defined(__ppc__)
+static inline int32 imuldiv8(int32 a, int32 b)
+{
+ register int32 ret,rah,ral,rlh,rll;
+ __asm__ ("mulhw %0,%7,%8\n\t"
+ "mullw %1,%7,%8\n\t"
+ "rlwinm %2,%0,24,0,7\n\t"
+ "rlwinm %3,%1,24,8,31\n\t"
+ "or %4,%2,%3"
+ :"=r"(rah),"=r"(ral),
+ "=r"(rlh),"=r"(rll),
+ "=r"(ret),
+ "=r"(a),"=r"(b)
+ :"5"(a),"6"(b));
+ return ret;
+}
+
+static inline int32 imuldiv16(int32 a, int32 b)
+{
+ register int32 ret,rah,ral,rlh,rll;
+ __asm__ ("mulhw %0,%7,%8\n\t"
+ "mullw %1,%7,%8\n\t"
+ "rlwinm %2,%0,16,0,15\n\t"
+ "rlwinm %3,%1,16,16,31\n\t"
+ "or %4,%2,%3"
+ :"=r"(rah),"=r"(ral),
+ "=r"(rlh),"=r"(rll),
+ "=r"(ret),
+ "=r"(a),"=r"(b)
+ :"5"(a),"6"(b));
+ return ret;
+}
+
+static inline int32 imuldiv24(int32 a, int32 b)
+{
+ register int32 ret,rah,ral,rlh,rll;
+ __asm__ ("mulhw %0,%7,%8\n\t"
+ "mullw %1,%7,%8\n\t"
+ "rlwinm %2,%0,8,0,23\n\t"
+ "rlwinm %3,%1,8,24,31\n\t"
+ "or %4,%2,%3"
+ :"=r"(rah),"=r"(ral),
+ "=r"(rlh),"=r"(rll),
+ "=r"(ret),
+ "=r"(a),"=r"(b)
+ :"5"(a),"6"(b));
+ return ret;
+}
+
+static inline int32 imuldiv28(int32 a, int32 b)
+{
+ register int32 ret,rah,ral,rlh,rll;
+ __asm__ ("mulhw %0,%7,%8\n\t"
+ "mullw %1,%7,%8\n\t"
+ "rlwinm %2,%0,4,0,27\n\t"
+ "rlwinm %3,%1,4,28,31\n\t"
+ "or %4,%2,%3"
+ :"=r"(rah),"=r"(ral),
+ "=r"(rlh),"=r"(rll),
+ "=r"(ret),
+ "=r"(a),"=r"(b)
+ :"5"(a),"6"(b));
+ return ret;
+}
+
+#else
+/* Generic version of imuldiv. */
#define imuldiv8(a, b) \
(int32)(((int64)(a) * (int64)(b)) >> 8)
@@ -71,10 +251,13 @@
#define imuldiv28(a, b) \
(int32)(((int64)(a) * (int64)(b)) >> 28)
+#endif /* architectures */
+
static inline int32 signlong(int32 a)
{
return ((a | 0x7fffffff) >> 30);
}
+#endif /* OPT_MODE != 0 */
/*****************************************************************************/
#if USE_ALTIVEC

0 comments on commit dc0514f

Please sign in to comment.