summaryrefslogtreecommitdiffstats
path: root/player/loadfile.c
diff options
context:
space:
mode:
authorAlessandro Ghedini <alessandro@ghedini.me>2014-03-30 19:05:59 +0200
committerwm4 <wm4@nowhere>2014-03-30 20:04:20 +0200
commit01e8a9c9e3a28f2beb41a5ee6d902797abdb74f0 (patch)
tree27261c599952e26dfc7af83e4b83595495c8c21f /player/loadfile.c
parent239dc2851a9001ff3c69c613d621125c9a95e8ae (diff)
downloadmpv-01e8a9c9e3a28f2beb41a5ee6d902797abdb74f0.tar.bz2
mpv-01e8a9c9e3a28f2beb41a5ee6d902797abdb74f0.tar.xz
encode_lavc: copy metadata to output file
Closes #684 Signed-off-by: wm4 <wm4@nowhere> Includes some minor cosmetic changes additional to the original PR.
Diffstat (limited to 'player/loadfile.c')
-rw-r--r--player/loadfile.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/player/loadfile.c b/player/loadfile.c
index e90c3b6200..95cc871e42 100644
--- a/player/loadfile.c
+++ b/player/loadfile.c
@@ -1272,6 +1272,10 @@ goto_reopen_demuxer: ;
encode_lavc_expect_stream(mpctx->encode_lavc_ctx, AVMEDIA_TYPE_VIDEO);
if (mpctx->encode_lavc_ctx && mpctx->current_track[0][STREAM_AUDIO])
encode_lavc_expect_stream(mpctx->encode_lavc_ctx, AVMEDIA_TYPE_AUDIO);
+ if (mpctx->encode_lavc_ctx) {
+ encode_lavc_set_metadata(mpctx->encode_lavc_ctx,
+ mpctx->demuxer->metadata);
+ }
#endif
reinit_video_chain(mpctx);