Next: , Previous: , Up: GL API   [Index]


3.4.3 Per-Fragment Operations

Function: set-gl-stencil-function stencil-function k [#:mask] [#:face]

Set the front and/or back function and the reference value k for stencil testing. Without the face keyword argument, both functions are set. The default mask is all-inclusive.

Function: set-gl-stencil-operation stencil-fail depth-fail depth-pass [#:face]

Set the front and/or back stencil test actions. Without the face keyword argument, both stencil test actions are set. See the stencil-op enumeration for possible values for stencil-fail, depth-fail, and depth-pass.

Function: set-gl-blend-equation mode-rgb [mode-alpha=mode-rgb]

Set the blend equation. With one argument, set the same blend equation for all components. Pass two arguments to specify a separate equation for the alpha component.

Function: set-gl-blend-function src-rgb dest-rgb [src-alpha=src-rgb] [dest-alpha=dest-rgb]

Set the blend function. With two arguments, set the same blend function for all components. Pass an additional two arguments to specify separate functions for the alpha components.

Function: set-gl-scissor x y width height

Define the scissor box. The box is defined in window coordinates, with (x,y) being the lower-left corner of the box.

Function: set-gl-sample-coverage value invert

Specify multisample coverage parameters.

Function: set-gl-alpha-function func ref

Specify the alpha test function. See the alpha-function enumerator.

Function: set-gl-depth-function func

Specify the depth test function. See the depth-function enumerator.

Function: set-gl-blend-color r g b a

Specify the blend color.

Function: set-gl-logic-operation opcode

Specify a logical pixel operation for color index rendering.

3.4.3.1 Whole Framebuffer Operations

Function: set-gl-draw-buffers buffers

Specify a list of color buffers to be drawn into. buffers should be a list of draw-buffer-mode enumerated values.

Function: set-gl-stencil-mask mask [#:face]

Control the writing of individual bits into the front and/or back stencil planes. With one argument, the stencil mask for both states are set.

Function: set-gl-draw-buffer mode

Specify the buffer or buffers to draw into.

Function: set-gl-index-mask mask

Control the writing of individual bits into the color index buffers.

Function: set-gl-color-mask red? green? blue? alpha?

Enable and disable writing of frame buffer color components.

Function: set-gl-depth-mask enable?

Enable and disable writing into the depth buffer.

Function: gl-clear mask

Clear a set of buffers to pre-set values. Use the clear-buffer-mask enumerator to specify which buffers to clear.

Function: set-gl-clear-color r g b a

Set the clear color for the color buffers.

Function: set-gl-clear-index c

Set the clear index for the color index buffers.

Function: set-gl-clear-depth depth

Set the clear value for the depth buffer.

Function: set-gl-clear-stencil-value s

Set the clear value for the stencil buffer.

Function: set-gl-clear-accumulation-color r g b a

Set the clear color for the accumulation buffer.

Function: set-gl-accumulation-buffer-operation op value

Operate on the accumulation buffer. op may be one of the accum-op enumerated values. The interpretation of value depends on op.

3.4.3.2 Drawing, Reading and Copying Pixels

Function: set-gl-read-buffer mode

Select a color buffer source for pixels. Use read-buffer-mode to select a mode.

Function: gl-copy-pixels x y width height type

Copy pixels from a screen-aligned rectangle in the frame buffer to a region relative to the current raster position. type selects which buffer to copy from.


Next: , Previous: , Up: GL API   [Index]