[prev in list] [next in list] [prev in thread] [next in thread] 

List:       mythtv-dev
Subject:    [mythtv] [patch] WMA support for MythMusic
From:       "Kevin Kuphal" <kevin.kuphal () myrealbox ! com>
Date:       2003-12-31 22:52:47
Message-ID: 0f2001c3cff0$d2bfed40$4001a8c0 () phoenix
[Download RAW message or body]

This patch adds WMA decoding support via libavformat/libavcodec to
MythMusic.  It does not support fast forward or rewind during playback =
at
this time as the libavformat for ASF/WMA files lacks this feature =
currently.
It should work fine with the libavformat/libavcodec provided by MythTV
although I tested with the latest CVS from ffmpeg (someone can verify =
this).

This is my first patch so be gentle :)

Kevin Kuphal

["avfdecoder.diff" (application/octet-stream)]

? mythmusic/mythmusic/avfdecoder.cpp
? mythmusic/mythmusic/avfdecoder.h
Index: mythmusic/mythmusic/decoder.cpp
===================================================================
RCS file: /var/lib/mythcvs/mythmusic/mythmusic/decoder.cpp,v
retrieving revision 1.6
diff -u -d -r1.6 decoder.cpp
--- mythmusic/mythmusic/decoder.cpp	17 Aug 2003 15:07:02 -0000	1.6
+++ mythmusic/mythmusic/decoder.cpp	31 Dec 2003 22:41:48 -0000
@@ -100,6 +100,7 @@
         Decoder::registerFactory(new MadDecoderFactory);
         Decoder::registerFactory(new FlacDecoderFactory);
         Decoder::registerFactory(new CdDecoderFactory);
+	Decoder::registerFactory(new avfDecoderFactory);
     }
 }
 
Index: mythmusic/mythmusic/decoder.h
===================================================================
RCS file: /var/lib/mythcvs/mythmusic/mythmusic/decoder.h,v
retrieving revision 1.5
diff -u -d -r1.5 decoder.h
--- mythmusic/mythmusic/decoder.h	4 May 2003 00:18:16 -0000	1.5
+++ mythmusic/mythmusic/decoder.h	31 Dec 2003 22:41:48 -0000
@@ -155,4 +155,13 @@
     Decoder *create(const QString &, QIODevice *, Output *, bool);
 };
 
+class avfDecoderFactory : public DecoderFactory
+{
+public:
+    bool supports(const QString &) const;
+    const QString &extension() const;
+    const QString &description() const;
+    Decoder *create(const QString &, QIODevice *, Output *, bool);
+};
+
 #endif
Index: mythmusic/mythmusic/mythmusic.pro
===================================================================
RCS file: /var/lib/mythcvs/mythmusic/mythmusic/mythmusic.pro,v
retrieving revision 1.21
diff -u -d -r1.21 mythmusic.pro
--- mythmusic/mythmusic/mythmusic.pro	30 Oct 2003 06:21:30 -0000	1.21
+++ mythmusic/mythmusic/mythmusic.pro	31 Dec 2003 22:41:48 -0000
@@ -24,6 +24,7 @@
 
 LIBS += -lmad -lid3tag -logg -lvorbisfile -lvorbis -lvorbisenc -lcdaudio -lFLAC
 LIBS += -lmp3lame -lcdda_paranoia -lcdda_interface
+LIBS += -lavcodec -lavformat
 
 # Input
 HEADERS += audiooutput.h buffer.h cddecoder.h cdrip.h constants.h databasebox.h 
@@ -35,6 +36,7 @@
 HEADERS += goom/filters.h goom/goomconfig.h goom/goom_core.h goom/graphic.h
 HEADERS += goom/ifs.h goom/lines.h goom/mythgoom.h goom/drawmethods.h
 HEADERS += goom/mmx.h goom/mathtools.h goom/tentacle3d.h goom/v3d.h
+HEADERS += avfdecoder.h
 
 SOURCES += audiooutput.cpp cddecoder.cpp cdrip.cpp databasebox.cpp decoder.cpp 
 SOURCES += flacdecoder.cpp flacencoder.cpp maddecoder.cpp main.cpp
@@ -45,3 +47,4 @@
 SOURCES += goom/filters.c goom/goom_core.c goom/graphic.c goom/tentacle3d.c
 SOURCES += goom/ifs.c goom/ifs_display.c goom/lines.c goom/surf3d.c 
 SOURCES += goom/zoom_filter_mmx.c goom/zoom_filter_xmmx.c goom/mythgoom.cpp
+SOURCES += avfdecoder.cpp


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic