summaryrefslogtreecommitdiff
path: root/ffmpeg.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-02-18 07:53:05 +0100
committerMichael Niedermayer <michaelni@gmx.at>2012-02-18 14:34:16 +0100
commitf3bd226de653fe1335a6b33a41319e106c16204c (patch)
tree32533a5eec2f34702a1376be4131ddb635d4332f /ffmpeg.c
parentad8173eb818a4de4fc61ac1b3ede886316f20eb5 (diff)
ffmpeg: Fix setting flags for codec copy.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'ffmpeg.c')
-rw-r--r--ffmpeg.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/ffmpeg.c b/ffmpeg.c
index dfe739463f..8f6f039f91 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -4402,6 +4402,18 @@ static void opt_output_file(void *optctx, const char *filename)
}
}
+
+ for (i = nb_output_streams - oc->nb_streams; i < nb_output_streams; i++) { //for all streams of this output file
+ AVDictionaryEntry *e;
+ ost = &output_streams[i];
+
+ if ( ost->stream_copy
+ && (e = av_dict_get(codec_opts, "flags", NULL, AV_DICT_IGNORE_SUFFIX))
+ && (!e->key[5] || check_stream_specifier(oc, ost->st, e->key+6)))
+ if (av_opt_set(ost->st->codec, "flags", e->value, 0) < 0)
+ exit_program(1);
+ }
+
/* handle attached files */
for (i = 0; i < o->nb_attachments; i++) {
AVIOContext *pb;