disable unused mpv events

This commit is contained in:
stax76
2022-07-11 06:57:10 +02:00
parent ec17ae8ce9
commit 6157a01701
2 changed files with 15 additions and 0 deletions

View File

@@ -118,6 +118,18 @@ namespace mpvnet
Handle = mpv_create();
mpv_event_id[] events = {
mpv_event_id.MPV_EVENT_START_FILE,
mpv_event_id.MPV_EVENT_AUDIO_RECONFIG,
mpv_event_id.MPV_EVENT_FILE_LOADED,
mpv_event_id.MPV_EVENT_VIDEO_RECONFIG,
mpv_event_id.MPV_EVENT_PLAYBACK_RESTART,
mpv_event_id.MPV_EVENT_END_FILE
};
foreach (mpv_event_id i in events)
mpv_request_event(Handle, i, 0);
mpv_request_log_messages(Handle, "no");
App.RunTask(() => MainEventLoop());