[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-core-devel
Subject: Re: patch for arts on ppc
From: Thomas <zander () xs4all ! nl>
Date: 2000-10-07 8:59:04
[Download RAW message or body]
Yep this works. !
I have working ppc and intel machines which both work, someone wants to comment
on this?
I want to commit this :)
> > There are the following problems on ppc:
> > - kaiman only does static (really loud), because this patch finally starts
> > artsd, the problem may lay elsewere.
> > - xmms does not work anymore when artsd is running (it completely freezes)
>
> This sounds like a byte order issue. From the way you describe it, and looking
> at the sources, I would say it is this:
Index: lib/splay/mpegsound.h
===================================================================
RCS file: /home/kde/kdemultimedia/mpeglib/lib/splay/mpegsound.h,v
retrieving revision 1.2
diff -u -3 -p -r1.2 mpegsound.h
--- lib/splay/mpegsound.h 2000/07/17 15:40:07 1.2
+++ lib/splay/mpegsound.h 2000/10/07 08:56:35
@@ -331,7 +331,7 @@ private:
short int rawdata[RAWDATASIZE];
void clearrawdata(void) {rawdataoffset=0;};
- void putraw(short int pcm) {rawdata[rawdataoffset++]=pcm;};
+ void putraw(short int pcm);
abs_thread_t thread;
Index: lib/splay/mpegtoraw.cc
===================================================================
RCS file: /home/kde/kdemultimedia/mpeglib/lib/splay/mpegtoraw.cc,v
retrieving revision 1.5
diff -u -3 -p -r1.5 mpegtoraw.cc
--- lib/splay/mpegtoraw.cc 2000/08/30 20:23:32 1.5
+++ lib/splay/mpegtoraw.cc 2000/10/07 08:56:36
@@ -16,6 +16,7 @@
#include <sys/types.h>
#include <unistd.h>
#include <iostream.h>
+#include <config.h>
/*Threads and usleep does not work, select is very portable*/
static void dosleep(int msec) {
@@ -257,8 +258,12 @@ int Mpegtoraw::decode(MpegAudioHeader* m
}
-
-
-
-
+// put mpeg to raw, fix big endieness..
+void Mpegtoraw::putraw(short int pcm) {
+#ifdef WORDS_BIGENDIAN
+ rawdata[rawdataoffset++]= ((pcm & 0xff) << 8) | ((pcm >> 8) & 0xff);
+#else
+ rawdata[rawdataoffset++]=pcm;
+#endif
+};
--
Thomas Zander zander@earthling.net
The only thing worse than failure is the fear of trying something new
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic