[FFmpeg-cvslog] avcodec_get_context_defaults3: set codec_id
Michael Niedermayer
git at videolan.org
Mon Apr 22 21:54:50 CEST 2013
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Mon Apr 22 21:37:25 2013 +0200| [2ae91c86f3869b656b58ee3ee1f5fd2922d7b659] | committer: Michael Niedermayer
avcodec_get_context_defaults3: set codec_id
Fixes Ticket1996
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=2ae91c86f3869b656b58ee3ee1f5fd2922d7b659
---
libavcodec/options.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/libavcodec/options.c b/libavcodec/options.c
index 1d10128..e1349dd 100644
--- a/libavcodec/options.c
+++ b/libavcodec/options.c
@@ -102,6 +102,9 @@ int avcodec_get_context_defaults3(AVCodecContext *s, const AVCodec *codec)
s->av_class = &av_codec_context_class;
s->codec_type = codec ? codec->type : AVMEDIA_TYPE_UNKNOWN;
+ if (codec)
+ s->codec_id = codec->id;
+
if(s->codec_type == AVMEDIA_TYPE_AUDIO)
flags= AV_OPT_FLAG_AUDIO_PARAM;
else if(s->codec_type == AVMEDIA_TYPE_VIDEO)
More information about the ffmpeg-cvslog
mailing list