java.lang.Object
de.grogra.glsl.utility.GLSLShader
de.grogra.glsl.utility.GLSLManagedShader
de.grogra.glsl.material.GLSLMaterial
de.grogra.glsl.material.GLSLPhong
- All Implemented Interfaces:
GLSLOpenGLObject
Implementation of Shader: Phong. Will recompile on every property change!
- Author:
- Konni Hartmann
-
Field Summary
Fields inherited from class de.grogra.glsl.utility.GLSLManagedShader
config
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected Result[]
getAllChannels
(Object sha) For "hardcompiled" Shaders this method should return a new instanceboolean
boolean
mayDiscard
(Object s) boolean
Return false if Shader depends only on UniformsMethods inherited from class de.grogra.glsl.material.GLSLMaterial
getFragmentShader, setupDynamicUniforms, setupShader, setupUniforms
Methods inherited from class de.grogra.glsl.utility.GLSLManagedShader
deleteShader, getConfig, getMaterial_stamp, setConfig, setMaterial_stamp
Methods inherited from class de.grogra.glsl.utility.GLSLShader
activateShader, cleanup, getShaderProgramNumber, getVertexShader, printProgramInfoLog
-
Constructor Details
-
GLSLPhong
public GLSLPhong()
-
-
Method Details
-
getAllChannels
- Specified by:
getAllChannels
in classGLSLMaterial
-
instanceFor
- Overrides:
instanceFor
in classGLSLShader
- Returns:
- Class represented by this Shader
-
needsRecompilation
Description copied from class:GLSLShader
Return false if Shader depends only on Uniforms- Overrides:
needsRecompilation
in classGLSLShader
- Returns:
- true, if Sourcecode needs to be regenerated and recompiled
-
getInstance
Description copied from class:GLSLShader
For "hardcompiled" Shaders this method should return a new instance- Overrides:
getInstance
in classGLSLShader
- Returns:
-
mayDiscard
- Overrides:
mayDiscard
in classGLSLMaterial
- Parameters:
s
- GroImp Shader that acts as a base for this shader- Returns:
- True, if fragments may be discarded by this shader
-
isOpaque
- Overrides:
isOpaque
in classGLSLMaterial
-