summaryrefslogtreecommitdiffstats
path: root/video/out/vo_xv.c
diff options
context:
space:
mode:
authorDudemanguy <random342@airmail.cc>2023-10-11 11:34:14 -0500
committerDudemanguy <random342@airmail.cc>2023-10-16 15:38:59 +0000
commitde9b800879706734721810427248e75ea5bdc0f9 (patch)
treef2cc425e6050d215b239372e2dba88167aaf7d5e /video/out/vo_xv.c
parent9d3e607cf749b7be057ba8f30ffd3d55c695a70b (diff)
downloadmpv-de9b800879706734721810427248e75ea5bdc0f9.tar.bz2
mpv-de9b800879706734721810427248e75ea5bdc0f9.tar.xz
timer: add convenience time unit conversion macros
There's a lot of wild 1e6, 1000, etc. lying around in the code. A macro is much easier to read and understand at a glance. Add some helpers for this. We don't need to convert everything now but there's some simple things that can be done so they are included in this commit.
Diffstat (limited to 'video/out/vo_xv.c')
-rw-r--r--video/out/vo_xv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/video/out/vo_xv.c b/video/out/vo_xv.c
index cffd3a797f..6c776c507b 100644
--- a/video/out/vo_xv.c
+++ b/video/out/vo_xv.c
@@ -670,7 +670,7 @@ static void wait_for_completion(struct vo *vo, int max_outstanding)
" for XShm completion events...\n");
ctx->Shm_Warned_Slow = 1;
}
- mp_sleep_ns(1e6);
+ mp_sleep_ns(MP_TIME_MS_TO_NS(1));
vo_x11_check_events(vo);
}
}