summaryrefslogtreecommitdiffstats
path: root/player
diff options
context:
space:
mode:
Diffstat (limited to 'player')
-rw-r--r--player/command.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/player/command.c b/player/command.c
index ae01796f31..c490f9db61 100644
--- a/player/command.c
+++ b/player/command.c
@@ -1742,6 +1742,17 @@ static int mp_property_cache_buffering(void *ctx, struct m_property *prop,
return m_property_int_ro(action, arg, state);
}
+static int mp_property_demuxer_is_network(void *ctx, struct m_property *prop,
+ int action, void *arg)
+{
+ MPContext *mpctx = ctx;
+ if (!mpctx->demuxer)
+ return M_PROPERTY_UNAVAILABLE;
+
+ return m_property_flag_ro(action, arg, mpctx->demuxer->is_network);
+}
+
+
static int mp_property_clock(void *ctx, struct m_property *prop,
int action, void *arg)
{
@@ -3906,6 +3917,7 @@ static const struct m_property mp_properties_base[] = {
{"demuxer-cache-idle", mp_property_demuxer_cache_idle},
{"cache-buffering-state", mp_property_cache_buffering},
{"paused-for-cache", mp_property_paused_for_cache},
+ {"demuxer-via-network", mp_property_demuxer_is_network},
{"clock", mp_property_clock},
{"seekable", mp_property_seekable},
{"partially-seekable", mp_property_partially_seekable},