Forces the running of GL subroutines in finite time.
OpenGL C bindings library: libGL.a
void glFlush( void )
Different GL implementations buffer subroutines in several different locations, including network buffers and the graphics accelerator itself. The glFlush subroutine empties all of these buffers, causing all issued subroutines to be executed as quickly as they are accepted by the actual rendering engine. Though this execution cannot be completed in any particular time period, it does complete in finite time.
Because any GL program might be executed over a network, or on an accelerator that buffers subroutines, all programs should call glFlush whenever they must have all of their previously issued subroutines completed. For example, call glFlush before waiting for user input that depends on the generated image.
The glFlush subroutine can return at any time. It does not wait until the execution of all previously issued OpenGL commands is complete.
|The glFlush subroutine is called between a call to glBegin and the corresponding call to glEnd.
|Contains C language constants, variable type definitions, and ANSI function prototypes for OpenGL.
The glBegin or glEnd subroutine, glFinish subroutine.