java.lang.Object
de.grogra.glsl.utility.ShaderConfiguration
de.grogra.glsl.material.MaterialConfiguration
- Direct Known Subclasses:
PlaneMaterialConfiguration
,SkyMaterialConfiguration
,SkyPreviewConfiguration
,TranspMaterialConfiguration
This class defines a state for a glsl-Shader, where individual ChannelMaps
may register Textures, TmpVariables or UniformVariables. It also may complete
a shader by querying all needed input from a GLSLCachedMaterial.
- Author:
- shi
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
Fields inherited from class de.grogra.glsl.utility.ShaderConfiguration
constVar, customSampler, funcMap, referenceKey, sampler, T_BOOL, T_FLOAT, T_MAT3, T_SAMPLER2D, T_SAMPLER2DRECT, T_SAMPLER2DSHADOW, T_SAMPLERCUBE, T_VEC2, T_VEC3, T_VEC4, uniform, USE_DERIVATES, USE_GLOBAL_POS, USE_LOCAL_POS, USE_UV, var, version
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionclone()
String[]
completeShader
(Result[] input) boolean
getShaderByDefaultCollection
(GLSLDisplay disp, Object reference) int
hashCode()
boolean
protected boolean
Should be implemented by ReferenceKey!void
set
(OpenGLState glState, GLSLDisplay disp, Object obj) protected void
Sets all permanent attributes of this instance to the values from other.void
setupDynamicUniforms
(javax.media.opengl.GL gl, GLSLDisplay disp, int shaderNo) void
setupShader
(javax.media.opengl.GL gl, GLSLDisplay disp, int shaderNo) Methods inherited from class de.grogra.glsl.utility.ShaderConfiguration
bindTextures, cleanUp, clearTmpVariables, getBit, getReferenceKeyValue, registerCustomTexture, registerFunc, registerGlobalConst, registerNewTmpVar, registerNewUniform, registerTexture, set, setBit, setupTextures, setVersion
-
Field Details
-
IT_NORMAL
public static final int IT_NORMAL- See Also:
-
IT_POSITION
public static final int IT_POSITION- See Also:
-
IT_SHININESS
public static final int IT_SHININESS- See Also:
-
IT_DIFFUSE
public static final int IT_DIFFUSE- See Also:
-
IT_SPECULAR
public static final int IT_SPECULAR- See Also:
-
IT_AMBIENT
public static final int IT_AMBIENT- See Also:
-
IT_EMISSIVE
public static final int IT_EMISSIVE- See Also:
-
IT_TRANSPERENCY
public static final int IT_TRANSPERENCY- See Also:
-
IT_DIFFUSE_TRANSPERENCY
public static final int IT_DIFFUSE_TRANSPERENCY- See Also:
-
IT_TRANSPERENCY_SHININESS
public static final int IT_TRANSPERENCY_SHININESS- See Also:
-
IT_PROLOGUE
public static final int IT_PROLOGUE- See Also:
-
-
Constructor Details
-
MaterialConfiguration
public MaterialConfiguration()
-
-
Method Details
-
isShaderAntialiasing
public boolean isShaderAntialiasing() -
completeShader
-
perInstance
protected boolean perInstance()Should be implemented by ReferenceKey! using a Interface or such- Overrides:
perInstance
in classShaderConfiguration
-
setThisToOther
Description copied from class:ShaderConfiguration
Sets all permanent attributes of this instance to the values from other. This method is used by clone() to generate a shallow copy of a ShaderConfiguration- Overrides:
setThisToOther
in classShaderConfiguration
- Parameters:
other
- Reference from which attributes are copied
-
clone
- Specified by:
clone
in classShaderConfiguration
-
hashCode
public int hashCode()- Overrides:
hashCode
in classShaderConfiguration
-
equals
- Overrides:
equals
in classShaderConfiguration
-
set
- Overrides:
set
in classShaderConfiguration
-
getDefaultInputChannel
-
getShaderByDefaultCollection
- Specified by:
getShaderByDefaultCollection
in classShaderConfiguration
-
setupShader
- Overrides:
setupShader
in classShaderConfiguration
-
setupDynamicUniforms
- Overrides:
setupDynamicUniforms
in classShaderConfiguration
-