[FFmpeg-cvslog] Allow auto-detection of ljpg images.

Carl Eugen Hoyos git at videolan.org
Wed Dec 7 02:33:36 CET 2011


ffmpeg | branch: master | Carl Eugen Hoyos <cehoyos at ag.or.at> | Wed Dec  7 02:32:59 2011 +0100| [c1e2ca1e31e4d244c0c16654bbc9d8964d21b99d] | committer: Carl Eugen Hoyos

Allow auto-detection of ljpg images.

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=c1e2ca1e31e4d244c0c16654bbc9d8964d21b99d
---

 libavformat/img2.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/libavformat/img2.c b/libavformat/img2.c
index 18dde55..00c5013 100644
--- a/libavformat/img2.c
+++ b/libavformat/img2.c
@@ -284,6 +284,8 @@ static int read_header(AVFormatContext *s1, AVFormatParameters *ap)
         s->split_planes = str && !av_strcasecmp(str + 1, "y");
         st->codec->codec_type = AVMEDIA_TYPE_VIDEO;
         st->codec->codec_id = av_str2id(img_tags, s->path);
+        if (st->codec->codec_id = CODEC_ID_LJPEG)
+            st->codec->codec_id = CODEC_ID_MJPEG;
     }
     if(st->codec->codec_type == AVMEDIA_TYPE_VIDEO && pix_fmt != PIX_FMT_NONE)
         st->codec->pix_fmt = pix_fmt;



More information about the ffmpeg-cvslog mailing list