System Time Measurement Functions.
This header provides common time measurement functions for retrieving the current date, time, and high-resolution timestamps from the system clock. It offers functions to obtain the current calendar date, time, and to compute elapsed time intervals (in milliseconds) using a stopwatch mechanism. These functions facilitate performance measurements and time-based operations in a cross-platform manner.
#define TIMESTAMP_SIZE QSC_TIMEREX_TIMESTAMP_MAX
char date[TIMESTAMP_SIZE];
printf("Current Date: %s\n", date);
printf("Elapsed Time: %llu ms\n", (unsigned long long)elapsed);
QSC_EXPORT_API void qsc_timerex_get_date(char output[QSC_TIMEREX_TIMESTAMP_MAX])
Get the calendar date from the current locale.
Definition timerex.c:7
QSC_EXPORT_API uint64_t qsc_timerex_stopwatch_start(void)
Returns the clock time at the start of a timed operation.
Definition timerex.c:141
QSC_EXPORT_API uint64_t qsc_timerex_stopwatch_elapsed(uint64_t start)
Returns the time difference between the start and current time in milliseconds.
Definition timerex.c:150
Reference Links: