summaryrefslogtreecommitdiffstats
path: root/input/input.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2012-08-19 18:07:06 +0200
committerwm4 <wm4@nowhere>2012-09-18 20:58:16 +0200
commit13482fb397ce6bbcec8a9342015f21d48fb7efe6 (patch)
treeb01882ba084afe0e3e635a3925cc589d913348a9 /input/input.c
parent1fb275b7de1f58a14182594996930860295af6c4 (diff)
downloadmpv-13482fb397ce6bbcec8a9342015f21d48fb7efe6.tar.bz2
mpv-13482fb397ce6bbcec8a9342015f21d48fb7efe6.tar.xz
core: refactor MPContext.demuxer field accesses
Whenever the demuxer is accessed to retrieve metadata, use the newly introduced master_demuxer field instead. If a timeline is used, the master_demuxer will still refer to the main file, instead to segments. Instead of mpctx->demuxer->stream, access mpctx->stream; even though they are the same, the code becomes shorter. For the TV code, introduce a function get_tvh() to access the TV handle, instead of duplicating the code all over the place. Often the demuxer field is checked to determine whether something is currently played; prefer other methods over that. Note that the code before always accessed the current timeline segment, and would e.g. read file metadata of the current segment. Now it always returns metadata for the master file. This may have various wanted and unwanted effects.
Diffstat (limited to 'input/input.c')
0 files changed, 0 insertions, 0 deletions