Refactor fwCore::HiResClock
Summary
HiResClock is currently implemented differently on Windows and other systems:
- Windows uses the
QueryPerformanceCounter
Windows API function. - Other systems use the
gettimeofday
function.
The Windows API documentation states:
QPC (QueryPerformanceCounter) is independent of and isn't synchronized to any external time reference.
This is kind of problematic when trying to synchronize fw4spl timestamps with timestamps from other sources as the epoch is undefined.
What is the expected correct behavior?
UNIX timestamps would be nice.
Possible fixes
Rewrite the damn thing using std::chrono
.