aboutsummaryrefslogtreecommitdiff
path: root/src/plugins/Input/ffmpeg/decoderffmpegfactory.cpp
diff options
context:
space:
mode:
authortrialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38>2010-01-06 20:12:30 +0000
committertrialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38>2010-01-06 20:12:30 +0000
commit7683057b2a0927288461cd7ffba03cd79b3e61f6 (patch)
treeba82832e8d5c147c29fb86d2886871fdac543730 /src/plugins/Input/ffmpeg/decoderffmpegfactory.cpp
parent7c912726598715813996ebd570805463136cd04b (diff)
downloadqmmp-7683057b2a0927288461cd7ffba03cd79b3e61f6.tar.gz
qmmp-7683057b2a0927288461cd7ffba03cd79b3e61f6.tar.bz2
qmmp-7683057b2a0927288461cd7ffba03cd79b3e61f6.zip
improved ffmpeg plugin: added stream input, fixed some bugs
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@1483 90c681e8-e032-0410-971d-27865f9a5e38
Diffstat (limited to 'src/plugins/Input/ffmpeg/decoderffmpegfactory.cpp')
-rw-r--r--src/plugins/Input/ffmpeg/decoderffmpegfactory.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/plugins/Input/ffmpeg/decoderffmpegfactory.cpp b/src/plugins/Input/ffmpeg/decoderffmpegfactory.cpp
index ad4ea9e95..5af4e41d6 100644
--- a/src/plugins/Input/ffmpeg/decoderffmpegfactory.cpp
+++ b/src/plugins/Input/ffmpeg/decoderffmpegfactory.cpp
@@ -87,15 +87,14 @@ const DecoderProperties DecoderFFmpegFactory::properties() const
properties.shortName = "ffmpeg";
properties.hasAbout = TRUE;
properties.hasSettings = TRUE;
- properties.noInput = TRUE;
- properties.protocols = "file";
+ properties.noInput = FALSE;
+ //properties.protocols = "file";
return properties;
}
Decoder *DecoderFFmpegFactory::create(const QString &path, QIODevice *input)
{
- Q_UNUSED(input);
- return new DecoderFFmpeg(path);
+ return new DecoderFFmpeg(path, input);
}
QList<FileInfo *> DecoderFFmpegFactory::createPlayList(const QString &fileName, bool useMetaData)
@@ -104,9 +103,9 @@ QList<FileInfo *> DecoderFFmpegFactory::createPlayList(const QString &fileName,
avcodec_init();
avcodec_register_all();
av_register_all();
- AVFormatContext *in;
+ AVFormatContext *in = 0;
- if (av_open_input_file(&in, fileName.toLocal8Bit(), NULL,0, NULL) < 0)
+ if (av_open_input_file(&in, fileName.toLocal8Bit(), 0, 0, 0) < 0)
{
qDebug("DecoderFFmpegFactory: unable to open file");
return list;