Home / comp / gb.opengl / gl / clear 
Gl.Clear (gb.opengl)
Syntax
STATIC SUB Clear ( Mask AS Integer )

Clear buffers within the viewport

Parmeters

Description

  Gl.Clear sets the bitplane area of the window to values previously selected by Gl.ClearColor, Gl.ClearIndex, Gl.ClearDepth, Gl.ClearStencil, and Gl.ClearAccum. Multiple color buffers can be cleared simultaneously by selecting more than one buffer at a time using Gl.DrawBuffer.

  The pixel ownership test, the scissor test, dithering, and the buffer writemasks affect the operation of

  Gl.Clear takes a single argument that is the bitwise OR of several values indicating which buffer is to be cleared. The values are as follows:

The value to which each buffer is cleared depends on the setting of the clear value for that buffer.

If a buffer is not present, then a Gl.Clear directed at that buffer has no effect.

Associated Gets

Gl.GetAccumClearValue
Gl.GetDepthClearValue
Gl.GetIndexClearValue
Gl.GetColorClearValue
Gl.GetStencilClearValue


See also
Gl.ClearAccum , Gl.ClearColor , Gl.ClearDepth , Gl.ClearIndex , Gl.ClearStencil , Gl.DrawBuffer, Gl.Scissor