[FFmpeg-cvslog] lavf/nutenc: write stream metadata.

Nicolas George git at videolan.org
Tue Aug 21 00:01:47 CEST 2012


ffmpeg | branch: master | Nicolas George <nicolas.george at normalesup.org> | Sun Aug 19 00:30:30 2012 +0200| [ac45637324f0e6d4e3e6227f26d61203be162b87] | committer: Nicolas George

lavf/nutenc: write stream metadata.

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

 libavformat/nutenc.c |    3 +++
 1 file changed, 3 insertions(+)

diff --git a/libavformat/nutenc.c b/libavformat/nutenc.c
index 05d2b08..617ffb0 100644
--- a/libavformat/nutenc.c
+++ b/libavformat/nutenc.c
@@ -462,6 +462,7 @@ static int write_globalinfo(NUTContext *nut, AVIOContext *bc){
 static int write_streaminfo(NUTContext *nut, AVIOContext *bc, int stream_id){
     AVFormatContext *s= nut->avf;
     AVStream* st = s->streams[stream_id];
+    AVDictionaryEntry *t = NULL;
     AVIOContext *dyn_bc;
     uint8_t *dyn_buf=NULL;
     int count=0, dyn_size, i;
@@ -469,6 +470,8 @@ static int write_streaminfo(NUTContext *nut, AVIOContext *bc, int stream_id){
     if(ret < 0)
         return ret;
 
+    while ((t = av_dict_get(st->metadata, "", t, AV_DICT_IGNORE_SUFFIX)))
+        count += add_info(dyn_bc, t->key, t->value);
     for (i=0; ff_nut_dispositions[i].flag; ++i) {
         if (st->disposition & ff_nut_dispositions[i].flag)
             count += add_info(dyn_bc, "Disposition", ff_nut_dispositions[i].str);



More information about the ffmpeg-cvslog mailing list