java.lang.Object
de.grogra.glsl.utility.GLSLShader
de.grogra.glsl.utility.GLSLManagedShader
de.grogra.glsl.light.GLSLLightShader
de.grogra.glsl.light.GLSLPointLight
- All Implemented Interfaces:
GLSLOpenGLObject
- Direct Known Subclasses:
GLSLPointLightShadow
Implementation of the point light type.
- Author:
- Konni Hartmann
-
Field Summary
Modifier and TypeFieldDescriptionprotected String
protected String
protected String
protected String
protected String
Fields inherited from class de.grogra.glsl.light.GLSLLightShader
spec, stdV
Fields inherited from class de.grogra.glsl.utility.GLSLManagedShader
config
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionString[]
For "hardcompiled" Shaders this method should return a new instanceSets middle part of a light shader (after properties have been extracted from deferred-shading-texturesboolean
needsRecompilation
(Object data) Return false if Shader depends only on Uniformsvoid
setupDynamicUniforms
(javax.media.opengl.GL gl, GLSLDisplay disp, Object data, int shaderNo) Function that loads uniforms of the represented Shader.protected void
setupShader
(javax.media.opengl.GL gl, GLSLDisplay disp, Object data) Methods inherited from class de.grogra.glsl.light.GLSLLightShader
canDisplayShadows, getLightShaderConfig, getVertexShader, toString
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, printProgramInfoLog
-
Field Details
-
lightPos
-
col0
-
fade_power
-
fade_distance
-
radientPower
-
-
Constructor Details
-
GLSLPointLight
public GLSLPointLight()
-
-
Method Details
-
getLightFunction
Description copied from class:GLSLLightShader
Sets middle part of a light shader (after properties have been extracted from deferred-shading-textures- Overrides:
getLightFunction
in classGLSLLightShader
- Returns:
-
getFragmentShader
- Specified by:
getFragmentShader
in classGLSLShader
- Returns:
-
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
-
instanceFor
- Overrides:
instanceFor
in classGLSLShader
- Returns:
- Class represented by this Shader
-
getInstance
Description copied from class:GLSLShader
For "hardcompiled" Shaders this method should return a new instance- Overrides:
getInstance
in classGLSLShader
- Returns:
-
setupShader
- Overrides:
setupShader
in classGLSLLightShader
-
setupDynamicUniforms
public void setupDynamicUniforms(javax.media.opengl.GL gl, GLSLDisplay disp, Object data, int shaderNo) Description copied from class:GLSLShader
Function that loads uniforms of the represented Shader.- Overrides:
setupDynamicUniforms
in classGLSLLightShader
disp
- GLSLDisplay that tries using this shaderdata
- The GroIMP-Shader-Object represented by this shader.
-