Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

gluttimerfunc(3) [centos man page]

UNTITLED
LOCAL UNTITLED NAME
glutTimerFunc -- Sets the Timer callback for the current window. LIBRARY
OpenGLUT - idletimer SYNOPSIS
#include <openglut.h> void glutTimerFunc(unsigned int msec, void( *callback )( int data ), int data); PARAMETERS
msec Milliseconds till invocation. callback Client function for timer event. data Arbitrary data; passed to callback . DESCRIPTION
After at least msec milliseconds, OpenGLUT will call callback , passing in your user-supplied data parameter. OpenGLUT will call your function only once. This callback is not bound to any window. CAVEATS
Unlike most other callbacks, timers only occur once. Unlike most other callbacks, you cannot deregister a timer callback. Unlike most other callbacks, you can register an arbitrary number of timers. SEE ALSO
glutIdleFunc(3) glutMainLoop(3) glutMainLoopEvent(3) Epoch

Check Out this Related Man Page

UNTITLED
LOCAL UNTITLED NAME
glutSetWindow -- Select the <i>current window</i> LIBRARY
OpenGLUT - window SYNOPSIS
#include <openglut.h> void glutSetWindow(int ID); PARAMETERS
ID Window identifier DESCRIPTION
Sets the current window to ID. All OpenGL rendering goes to the current window . Many OpenGLUT functions also implicitly use the current window . Many OpenGLUT callback operations are tied to a window. When your callback is invoked, OpenGLUT will set that particular window to be the current window . However, some callbacks---such as that registered via glutIdleFunc()---do not have associated windows. If a callback is not associated to a particular window, then when OpenGLUT invokes that callback you should always use glutSetWindow() to select the appro- priate window before doing any OpenGL rendering or doing any OpenGLUT window-related operations. There may be cases when you can get away with assuming that the current window is unchanged since some prior time, but OpenGLUT has con- siderable liberaty with respect to when it invokes your functions. Also, your program may add more windows or more operations on other win- dows as you develop it. Lastly, this is a convenient way to select among multiple windows for drawing without actually waiting for that window's display callback. Simply set the current window and draw immediately. This is not always advisable, but may be practical. It is an error to set the current window to a non-existant window (e.g., one that you have closed). A warning will be printed on stderr if you try to do so, and the current window should be unchanged. SEE ALSO
glutGetWindow(3) Epoch
Man Page