summaryrefslogtreecommitdiff
path: root/ffmpeg.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2007-12-19 10:56:17 +0000
committerMichael Niedermayer <michaelni@gmx.at>2007-12-19 10:56:17 +0000
commit626004690c23c981f67228ea325dde3f35193988 (patch)
tree4c83eca851de2f715b7dcbd8a11b113d9422c516 /ffmpeg.c
parent379374ea11ea561729fc0c6dc38a06f9b5b43731 (diff)
Allow overriding codec_ids.
Originally committed as revision 11266 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'ffmpeg.c')
-rw-r--r--ffmpeg.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/ffmpeg.c b/ffmpeg.c
index ad97836174..1fbae5e515 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -2662,6 +2662,11 @@ static void opt_input_file(const char *filename)
if(str && (opt->flags & AV_OPT_FLAG_DECODING_PARAM))
av_set_string(ic, opt_names[i], str);
}
+
+ ic->video_codec_id = find_codec_or_die(video_codec_name , CODEC_TYPE_VIDEO , 0);
+ ic->audio_codec_id = find_codec_or_die(audio_codec_name , CODEC_TYPE_AUDIO , 0);
+ ic->subtitle_codec_id= find_codec_or_die(subtitle_codec_name, CODEC_TYPE_SUBTITLE, 0);
+
/* open the input file with generic libav function */
err = av_open_input_file(&ic, filename, file_iformat, 0, ap);
if (err < 0) {