New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a very basic time span API #657
Comments
See: |
Yes, the one in Fl_Timeout is not public and I looked for a better solution at that time. I'd like to see a method that can be used reliably also in timeout handling. IIRC the problem was (as most of the time ;-) ) Windows. Without using multimedia timers it's hard to find a Windows function that can reliably deliver a timer stamp that doesn't wrap around after some time (maybe 49 days IIRC, too lazy to check or calculate now). This must be taken into account for such a delta time calculation. I remember that I also found this getmillicount stuff, it might be worth a look. ... just took a quick look, it's "public domain", seems like we could use it. Anyway, if you can find a proper solution: +1 👍 for such a new feature. |
Brainstorm for myself:
|
Implemented in PR #670 |
For doing anything animated, it is useful to have a method to measure time spans that is independent on the actual execution time of
timeout
-callbacks. I would like to addFl::time_now_ms()
andFl::time_span_ms(t0, t1=0)
in a cross-platform way.http://www.firstobject.com/getmillicount-milliseconds-portable-c++.htm
The text was updated successfully, but these errors were encountered: