Phaser.Renderer.WebGL.WebGLStencilParametersFactory
Scope: static
Source: src/renderer/webgl/parameters/WebGLStencilParametersFactory.js#L7
Since: 4.0.0
Static functions
create
<instance> create(renderer, [enabled], [func], [funcRef], [funcMask], [opFail], [opZfail], [opZpass], [clear])
Description:
Creates a new WebGLStencilParameters.
Parameters:
| name | type | optional | default | description |
|---|---|---|---|---|
| renderer | Phaser.Renderer.WebGL.WebGLRenderer | No | The WebGLRenderer to create the WebGLStencilParameters for. | |
| enabled | GLboolean | Yes | false | Whether the stencil test is enabled. |
| func | GLenum | Yes | "GL_ALWAYS" | The comparison function. |
| funcRef | GLint | Yes | 0 | The reference value for the stencil test. |
| funcMask | GLuint | Yes | "0xFF" | The mask to apply to the stencil test. |
| opFail | GLenum | Yes | "GL_KEEP" | The operation to perform if the stencil test fails. |
| opZfail | GLenum | Yes | "GL_KEEP" | The operation to perform if the depth test fails. |
| opZpass | GLenum | Yes | "GL_KEEP" | The operation to perform if the stencil test passes and the depth test passes or is disabled. |
| clear | GLint | Yes | 0 | The value to clear the stencil buffer to. |
Returns: Phaser.Types.Renderer.WebGL.WebGLStencilParameters - The created WebGLStencilParameters.
Source: src/renderer/webgl/parameters/WebGLStencilParametersFactory.js#L15
Since: 4.0.0