diff --git a/libs/ardour/ardour/ardour.h b/libs/ardour/ardour/ardour.h index 6fba7992f0..9f20a466b3 100644 --- a/libs/ardour/ardour/ardour.h +++ b/libs/ardour/ardour/ardour.h @@ -83,8 +83,6 @@ namespace ARDOUR { LIBARDOUR_API bool translations_are_enabled (); LIBARDOUR_API bool set_translations_enabled (bool); - LIBARDOUR_API microseconds_t get_microseconds (); - LIBARDOUR_API void setup_fpu (); LIBARDOUR_API std::vector get_available_sync_options(); diff --git a/libs/ardour/ardour/types.h b/libs/ardour/ardour/types.h index 11d784079d..9938f3e999 100644 --- a/libs/ardour/ardour/types.h +++ b/libs/ardour/ardour/types.h @@ -47,6 +47,7 @@ #include "temporal/types.h" #include "pbd/id.h" +#include "pbd/microseconds.h" #include "evoral/Range.h" @@ -77,7 +78,7 @@ typedef float Sample; typedef float pan_t; typedef float gain_t; typedef uint32_t layer_t; -typedef uint64_t microseconds_t; +typedef PBD::microseconds_t microseconds_t; typedef uint32_t pframes_t; /* rebind Temporal position types into ARDOUR namespace */ diff --git a/libs/ardour/globals.cc b/libs/ardour/globals.cc index 91dc245661..ffc8b346b4 100644 --- a/libs/ardour/globals.cc +++ b/libs/ardour/globals.cc @@ -957,28 +957,6 @@ clock_gettime (int /*clk_id*/, struct timespec* t) } #endif -microseconds_t -ARDOUR::get_microseconds () -{ -#ifdef PLATFORM_WINDOWS - microseconds_t ret = 0; - LARGE_INTEGER freq, time; - - if (QueryPerformanceFrequency (&freq)) - if (QueryPerformanceCounter (&time)) - ret = (microseconds_t) ((time.QuadPart * 1000000) / freq.QuadPart); - - return ret; -#else - struct timespec ts; - if (clock_gettime (CLOCK_MONOTONIC, &ts) != 0) { - /* EEEK! */ - return 0; - } - return (microseconds_t)ts.tv_sec * 1000000 + (ts.tv_nsec / 1000); -#endif -} - /** Return the number of bits per sample for a given sample format. * * This is closely related to sndfile_data_width() but does NOT