Loading...
Searching...
No Matches
Clock.h File Reference
Go to the source code of this file.
Functions | |
sfClock * | sfClock_create (void) |
Create a new clock and start it. | |
sfClock * | sfClock_copy (const sfClock *clock) |
Create a new clock by copying an existing one. | |
void | sfClock_destroy (sfClock *clock) |
Destroy a clock. | |
sfTime | sfClock_getElapsedTime (const sfClock *clock) |
Get the time elapsed in a clock. | |
sfTime | sfClock_restart (sfClock *clock) |
Restart a clock. | |
Function Documentation
◆ sfClock_copy()
Create a new clock by copying an existing one.
- Parameters
-
clock Clock to copy
- Returns
- A new sfClock object which is a copy of clock
◆ sfClock_create()
sfClock * sfClock_create | ( | void | ) |
Create a new clock and start it.
- Returns
- A new sfClock object
◆ sfClock_destroy()
void sfClock_destroy | ( | sfClock * | clock | ) |
Destroy a clock.
- Parameters
-
clock Clock to destroy
◆ sfClock_getElapsedTime()
Get the time elapsed in a clock.
This function returns the time elapsed since the last call to sfClock_restart (or the construction of the object if sfClock_restart has not been called).
- Parameters
-
clock Clock object
- Returns
- Time elapsed