mirror of
https://github.com/mpv-player/mpv
synced 2024-12-25 08:12:17 +00:00
demux_lavf: update metadata with information from AV_PROGRAM on switch.
Need to trigger demux_changed() manually since metadata of tracks and streams is not changed, but demuxer-metadata is still changed on program switch.
This commit is contained in:
parent
9fb949b49a
commit
0c9b655477
@ -1062,6 +1062,12 @@ redo:
|
||||
goto redo;
|
||||
}
|
||||
priv->cur_program = prog->progid = program->id;
|
||||
|
||||
mp_tags_copy_from_av_dictionary(demuxer->metadata, priv->avfc->programs[p]->metadata);
|
||||
update_metadata(demuxer, NULL);
|
||||
// Enforce metadata update even if no explicit METADATA_UPDATED since we switched program.
|
||||
demux_changed(demuxer, DEMUX_EVENT_METADATA);
|
||||
|
||||
return DEMUXER_CTRL_OK;
|
||||
}
|
||||
case DEMUXER_CTRL_RESYNC:
|
||||
|
Loading…
Reference in New Issue
Block a user