Package de.coreengine.rendering.programs
Class ParticleShader
- java.lang.Object
-
- de.coreengine.rendering.programs.Shader
-
- de.coreengine.rendering.programs.ParticleShader
-
public class ParticleShader extends Shader
-
-
Field Summary
-
Fields inherited from class de.coreengine.rendering.programs.Shader
SHADERS_LOCATION
-
-
Constructor Summary
Constructors Constructor Description ParticleShader()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addShaders()
Adding shaders to programprotected void
bindAttribs()
Binding all vbo attributes to shader attribute ("in" variable)protected void
loadUniforms()
Loading uniform locationsvoid
prepareCam(Camera cam)
Prepare camera to render next particles fromvoid
prepareParticles(int texture)
Preparing stuff for next particlesvoid
setNextTransform(javax.vecmath.Vector2f size, javax.vecmath.Vector3f pos)
Set transformation for next particle-
Methods inherited from class de.coreengine.rendering.programs.Shader
addShader, bindAttribute, bindTexture, bindTextureUnit, getUniformLocation, setUniform, setUniform, setUniform, setUniform, setUniform, setUniform, setUniform, setUniform, setUniformArray1f, setUniformArray1i, setUniformArray2f, setUniformArray3f, start, stop
-
-
-
-
Method Detail
-
addShaders
protected void addShaders()
Description copied from class:Shader
Adding shaders to program- Specified by:
addShaders
in classShader
-
bindAttribs
protected void bindAttribs()
Description copied from class:Shader
Binding all vbo attributes to shader attribute ("in" variable)- Specified by:
bindAttribs
in classShader
-
loadUniforms
protected void loadUniforms()
Description copied from class:Shader
Loading uniform locations- Specified by:
loadUniforms
in classShader
-
prepareCam
public void prepareCam(Camera cam)
Prepare camera to render next particles from- Parameters:
cam
- Camera to render from
-
prepareParticles
public void prepareParticles(int texture)
Preparing stuff for next particles- Parameters:
texture
- TextureData of next particles
-
setNextTransform
public void setNextTransform(javax.vecmath.Vector2f size, javax.vecmath.Vector3f pos)
Set transformation for next particle- Parameters:
size
- Size of the next particlepos
- Position of the next particle
-
-