summaryrefslogtreecommitdiffstats
path: root/player
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2020-02-07 16:15:55 +0100
committerwm4 <wm4@nowhere>2020-02-07 16:15:55 +0100
commit11d223228cbaa22cbd42f2e8e2b7f5b6c12989a9 (patch)
treea1f8cdaaec60e9b103d5b08d1399770696eda9d3 /player
parent27d5d3202081ec8e328a928c117a43e3337aff83 (diff)
downloadmpv-11d223228cbaa22cbd42f2e8e2b7f5b6c12989a9.tar.bz2
mpv-11d223228cbaa22cbd42f2e8e2b7f5b6c12989a9.tar.xz
command: add cache-duration to cache state property
Convenience; see following commit.
Diffstat (limited to 'player')
-rw-r--r--player/command.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/player/command.c b/player/command.c
index 26438c06f6..3f13c39a02 100644
--- a/player/command.c
+++ b/player/command.c
@@ -1450,6 +1450,9 @@ static int mp_property_demuxer_cache_state(void *ctx, struct m_property *prop,
if (s.ts_reader != MP_NOPTS_VALUE)
node_map_add_double(r, "reader-pts", s.ts_reader);
+ if (s.ts_duration >= 0)
+ node_map_add_double(r, "cache-duration", s.ts_duration);
+
node_map_add_flag(r, "eof", s.eof);
node_map_add_flag(r, "underrun", s.underrun);
node_map_add_flag(r, "idle", s.idle);