]> git.xonotic.org Git - xonotic/xonotic.git/blobdiff - misc/buildfiles/osx/Xonotic-SDL.app/Contents/Frameworks/SDL.framework/Versions/A/Headers/SDL_timer.h
update to SDL 1.2.14
[xonotic/xonotic.git] / misc / buildfiles / osx / Xonotic-SDL.app / Contents / Frameworks / SDL.framework / Versions / A / Headers / SDL_timer.h
index d21159fed2d16d01fbaa3f0042ccfd8ece2e247e..d7cd0246012c52a4061a051cfcb9ca1315532ec9 100644 (file)
@@ -1,6 +1,6 @@
 /*
     SDL - Simple DirectMedia Layer
-    Copyright (C) 1997-2006 Sam Lantinga
+    Copyright (C) 1997-2009 Sam Lantinga
 
     This library is free software; you can redistribute it and/or
     modify it under the terms of the GNU Lesser General Public
@@ -23,7 +23,9 @@
 #ifndef _SDL_timer_h
 #define _SDL_timer_h
 
-/* Header for the SDL time management routines */
+/** @file SDL_timer.h
+ *  Header for the SDL time management routines
+ */
 
 #include "SDL_stdinc.h"
 #include "SDL_error.h"
 extern "C" {
 #endif
 
-/* This is the OS scheduler timeslice, in milliseconds */
+/** This is the OS scheduler timeslice, in milliseconds */
 #define SDL_TIMESLICE          10
 
-/* This is the maximum resolution of the SDL timer on all platforms */
-#define TIMER_RESOLUTION       10      /* Experimentally determined */
+/** This is the maximum resolution of the SDL timer on all platforms */
+#define TIMER_RESOLUTION       10      /**< Experimentally determined */
 
-/* Get the number of milliseconds since the SDL library initialization.
+/**
+ * Get the number of milliseconds since the SDL library initialization.
  * Note that this value wraps if the program runs for more than ~49 days.
  */ 
 extern DECLSPEC Uint32 SDLCALL SDL_GetTicks(void);
 
-/* Wait a specified number of milliseconds before returning */
+/** Wait a specified number of milliseconds before returning */
 extern DECLSPEC void SDLCALL SDL_Delay(Uint32 ms);
 
-/* Function prototype for the timer callback function */
+/** Function prototype for the timer callback function */
 typedef Uint32 (SDLCALL *SDL_TimerCallback)(Uint32 interval);
 
-/* Set a callback to run after the specified number of milliseconds has
+/**
+ * Set a callback to run after the specified number of milliseconds has
  * elapsed. The callback function is passed the current timer interval
  * and returns the next timer interval.  If the returned value is the 
  * same as the one passed in, the periodic alarm continues, otherwise a
@@ -68,7 +72,7 @@ typedef Uint32 (SDLCALL *SDL_TimerCallback)(Uint32 interval);
  * later on an unloaded system.  If you wanted to set a flag signaling
  * a frame update at 30 frames per second (every 33 ms), you might set a 
  * timer for 30 ms:
- *   SDL_SetTimer((33/10)*10, flag_update);
+ *   @code SDL_SetTimer((33/10)*10, flag_update); @endcode
  *
  * If you use this function, you need to pass SDL_INIT_TIMER to SDL_Init().
  *
@@ -81,11 +85,14 @@ typedef Uint32 (SDLCALL *SDL_TimerCallback)(Uint32 interval);
  */
 extern DECLSPEC int SDLCALL SDL_SetTimer(Uint32 interval, SDL_TimerCallback callback);
 
-/* New timer API, supports multiple timers
+/** @name New timer API
+ * New timer API, supports multiple timers
  * Written by Stephane Peter <megastep@lokigames.com>
  */
+/*@{*/
 
-/* Function prototype for the new timer callback function.
+/**
+ * Function prototype for the new timer callback function.
  * The callback function is passed the current timer interval and returns
  * the next timer interval.  If the returned value is the same as the one
  * passed in, the periodic alarm continues, otherwise a new alarm is
@@ -93,19 +100,22 @@ extern DECLSPEC int SDLCALL SDL_SetTimer(Uint32 interval, SDL_TimerCallback call
  */
 typedef Uint32 (SDLCALL *SDL_NewTimerCallback)(Uint32 interval, void *param);
 
-/* Definition of the timer ID type */
+/** Definition of the timer ID type */
 typedef struct _SDL_TimerID *SDL_TimerID;
 
-/* Add a new timer to the pool of timers already running.
-   Returns a timer ID, or NULL when an error occurs.
+/** Add a new timer to the pool of timers already running.
*  Returns a timer ID, or NULL when an error occurs.
  */
 extern DECLSPEC SDL_TimerID SDLCALL SDL_AddTimer(Uint32 interval, SDL_NewTimerCallback callback, void *param);
 
-/* Remove one of the multiple timers knowing its ID.
+/**
+ * Remove one of the multiple timers knowing its ID.
  * Returns a boolean value indicating success.
  */
 extern DECLSPEC SDL_bool SDLCALL SDL_RemoveTimer(SDL_TimerID t);
 
+/*@}*/
+
 /* Ends C function definitions when using C++ */
 #ifdef __cplusplus
 }