Add glfwGetTimerValue and glfwGetTimerFrequency

This adds raw timer access to the public API and builds the
floating-point time functions on top.  It also makes the GLFWuint64 type
public.
This commit is contained in:
Camilla Berglund
2016-03-06 11:38:55 +01:00
parent 8221aadea3
commit 31f67dd3cc
14 changed files with 148 additions and 96 deletions

View File

@@ -554,6 +554,21 @@ glfwSetTime(4.0);
This sets the timer to the specified time, in seconds.
You can also access the raw timer value, in 1 / frequency seconds,
with @ref glfwGetTimerValue.
@code
GLFWuint64 value = glfwGetTimerValue();
@endcode
The frequency of the raw timer varies depending on what time sources are
available on the machine. You can query its frequency, in Hz, with @ref
glfwGetTimerFrequency.
@code
GLFWuint64 freqency = glfwGetTimerFrequency();
@endcode
@section clipboard Clipboard input and output

View File

@@ -37,6 +37,12 @@ GLFW now supports window maximization with @ref glfwMaximizeWindow and the
GLFW now supports giving windows input focus with @ref glfwFocusWindow.
@subsection news_32_timer Raw timer access
GLFW now supports raw timer values with @ref glfwGetTimerValue and @ref
glfwGetTimerFrequency.
@section news_31 New features in 3.1
These are the release highlights. For a full list of changes see the