ClearCommand

ClearCommand

new

Represents a command to the renderer for clearing a framebuffer.

See:
Source:

Members

:Color

The value to clear the color buffer to. When undefined, the color buffer is not cleared.
Default Value:
  • undefined

:Number

The value to clear the depth buffer to. When undefined, the depth buffer is not cleared.
Default Value:
  • undefined

:Framebuffer

The framebuffer to clear.
Default Value:
  • undefined

:Object

The object who created this command. This is useful for debugging command execution; it allows you to see who created a command when you only have a reference to the command, and can be used to selectively execute commands with Scene#debugCommandFilter.
Default Value:
  • undefined
See:

:RenderState

The render state to apply when executing the clear command. The following states affect clearing: scissor test, color mask, depth mask, stencil mask, and dither. When the render state is undefined, the default render state is used.
Default Value:
  • undefined
See:

:Number

The value to clear the stencil buffer to. When undefined, the stencil buffer is not cleared.
Default Value:
  • undefined

<static, constant> :ClearCommand

Clears color to (0.0, 0.0, 0.0, 0.0); depth to 1.0; and stencil to 0.

Methods

Executes the clear command.

Parameters:
Name Type Argument Description
context Context The renderer context in which to clear.
passState PassState <optional>
The state for the current rendering pass.