Shader
class Shader
The Material Shader builder.
public class Shader
This class has a static subclass
class Builder
— Constructors (2) —
Constructor | Description |
---|---|
Builder() | Creates a new instance of Builder. |
Builder(String vertexCode, String fragmentCode) | Creates a new instance of Builder with the vertex code and fragment code defined to be the arguments. |
— Methods (23) —
Name | Description |
---|---|
String getVertexCode() | Returns the code of the current vertex of the Shader. |
[Builder] setVertexCode(String vertexCode) | Sets the code of the current vertex of the Shader. |
[Builder] setVertexCode(VertexGLSLFile] file) | Sets the code of the current vertex of the Shader. |
[Builder] setVertexCode(VertexShader vertexShader) | Sets the code of the current vertex of the Shader. |
String getGeometryCode() | Returns the current geometric code of the Shader. |
[Builder] setGeometryCode(String geometryCode) | Sets the current geometric code of the Shader. |
[Builder] setGeometryCode(GeometryGLSLFile file) | Sets the current geometric code of the Shader. |
[Builder] setGeometryCode([GeometryShader] fragmentShader) | Sets the current geometric code of the Shader. |
String getFragmentCode() | Returns the code of the current Shader fragment. |
[Builder] setFragmentCode(String fragmentCode) | Sets the code of the current Shader fragment. |
[Builder] setFragmentCode(FragmentGLSLFile file) | Sets the code of the current Shader fragment. |
[Builder] setFragmentCode([FragmentShader] fragmentShader) | Sets the code of the current Shader fragment. |
[Builder] createProgram() | Create a program. |
boolean isGeometryShaderActive() | Returns true if geometric shader is enabled, returns false if not. |
[Builder] activateGeometryShader(boolean value) | Defines whether or not the geometric shader will be enabled. |
[Builder] compileVertex() | Compiles the vertex of the Shader. |
[Builder] tryCompileVertex([CompileErrorListener] compileErrorListener) | Compiles the vertex of the Shader if it returns a [CompileErrorListener]. |
[Builder] compileGeometry() | Compiles the geometry of Shader. |
[Builder] tryCompileGeometry([CompileErrorListener] compileErrorListener) | Compiles Shader geometry if it returns a [CompileErrorListener]. |
[Builder] compileFragment() | Compiles the Shader fragment. |
[Builder] tryCompileFragment([CompileErrorListener] compileErrorListener) | Compiles the Shader fragment if it returns a [CompileErrorListener]. |
Shader create() | Create a Shader. |
Shader tryCreate([ShaderErrorListener] shaderErrorListener) | Creates a Shader if it returns a [ShaderErrorListener]. |