From 352eab7e76c21d21087daa11f0e5d10f1d92918b Mon Sep 17 00:00:00 2001 From: Martin Pulec Date: Wed, 13 Nov 2024 14:08:03 +0100 Subject: [PATCH] tv.h: added more unit-convert macros --- src/tv.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/tv.h b/src/tv.h index 29a5c6fc7..dcb3bb232 100644 --- a/src/tv.h +++ b/src/tv.h @@ -96,7 +96,9 @@ typedef long long time_ns_t; #define US_TO_MS(val_us) ((val_us) / 1000) #define MS_TO_US(val_ms) ((val_ms) * 1000) #define NS_TO_MS(val_ns) ((val_ns) / 1000 / 1000) +#define NS_TO_US(val_ns) ((val_ns) / 1000) #define MS_TO_NS(val_ms) ((val_ms) * 1000) +#define SEC_TO_NS(val_sec) ((val_sec) * 1000LL * 1000 * 1000) static inline time_ns_t get_time_in_ns() { #ifdef HAVE_TIMESPEC_GET