Represents a command to the renderer for GPU Compute (using old-school GPGPU).
Members
-
fragmentShaderSource : ShaderSource
-
The fragment shader source. The default vertex shader is ViewportQuadVS.
-
Default Value:
undefined
-
outputTexture : Texture
-
Texture to use for offscreen rendering.
-
Default Value:
undefined
-
The object who created this command. This is useful for debugging command execution; it allows us to see who created a command when we only have a reference to the command, and can be used to selectively execute commands with
Scene#debugCommandFilter
.-
Default Value:
- Scene#debugCommandFilter
undefined
See:
-
The pass when to render. Always compute pass.
-
Default Value:
Pass.COMPUTE;
-
Whether the renderer resources will persist beyond this call. If not, they will be destroyed after completion.
-
Default Value:
false
-
Function that is called after the ComputeCommand is executed. Takes the output texture as its single argument.
-
Default Value:
undefined
-
Function that is called immediately before the ComputeCommand is executed. Used to update any renderer resources. Takes the ComputeCommand as its single argument.
-
Default Value:
undefined
-
shaderProgram : ShaderProgram
-
The shader program to apply.
-
Default Value:
undefined
-
An object with functions whose names match the uniforms in the shader program and return values to set those uniforms.
-
Default Value:
undefined
-
vertexArray : VertexArray
-
The vertex array. If none is provided, a viewport quad will be used.
-
Default Value:
undefined
Methods
-
Executes the compute command.
Name Type Description computeEngine
Context The context that processes the compute command.