summaryrefslogtreecommitdiffstats
path: root/player/core.h
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2016-09-16 14:23:54 +0200
committerwm4 <wm4@nowhere>2016-09-16 14:37:48 +0200
commitb8ade7c99b830ee9870040bcfc1f2c3d3a64d172 (patch)
tree48df8031d90be4e6e1f9c9c4045a72e21c33862c /player/core.h
parentf845f64c2abe4361084b4bc07f5f1ea5dd43ec9f (diff)
downloadmpv-b8ade7c99b830ee9870040bcfc1f2c3d3a64d172.tar.bz2
mpv-b8ade7c99b830ee9870040bcfc1f2c3d3a64d172.tar.xz
player, ao, vo: don't call mp_input_wakeup() directly
Currently, calling mp_input_wakeup() will wake up the core thread (also called the playloop). This seems odd, but currently the core indeed calls mp_input_wait() when it has nothing more to do. It's done this way because MPlayer used input_ctx as central "mainloop". This is probably going to change. Remove direct calls to this function, and replace it with mp_wakeup_core() calls. ao and vo are changed to use opaque callbacks and not use input_ctx for this purpose. Other code already uses opaque callbacks, or has legitimate reasons to use input_ctx directly (such as sending actual user input).
Diffstat (limited to 'player/core.h')
-rw-r--r--player/core.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/player/core.h b/player/core.h
index 0ffb47404c..3fa2c102b4 100644
--- a/player/core.h
+++ b/player/core.h
@@ -511,6 +511,8 @@ void set_osd_bar_chapters(struct MPContext *mpctx, int type);
// playloop.c
void mp_wait_events(struct MPContext *mpctx, double sleeptime);
+void mp_wakeup_core(struct MPContext *mpctx);
+void mp_wakeup_core_cb(void *ctx);
void mp_process_input(struct MPContext *mpctx);
double get_relative_time(struct MPContext *mpctx);
void reset_playback_state(struct MPContext *mpctx);