|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object codeanticode.glgraphics.GLCgShaderParameter
public class GLCgShaderParameter
Field Summary |
---|
Constructor Summary | |
---|---|
GLCgShaderParameter(processing.core.PApplet parent,
GLShader shader,
java.lang.String name,
java.lang.String label,
int type)
Creates an instance of GLCgShaderParameter using the specified parameters. |
|
GLCgShaderParameter(processing.core.PApplet parent,
java.lang.String name,
java.lang.String label,
int type)
Creates an instance of GLCgShaderParameter using the specified parameters. |
Method Summary | |
---|---|
boolean |
available()
Returns true or false depending on whether this variable is available for use. |
void |
copyToShader()
Copies the parameter value to the GPU. |
int |
getArrayLength()
Returns array length. |
java.lang.String |
getLabel()
Returns parameter label. |
java.lang.String |
getName()
Returns parameter name. |
int |
getType()
Returns parameter type. |
static int |
getType(java.lang.String typeStr)
Returns the int constant that identifies a type, given the corresponding string. |
void |
init()
Initializes this shader variable. |
void |
setProgramType(int type)
|
void |
setShader(GLShader shader)
Sets the shader this parameter corresponds to. |
void |
setValue(float value)
Sets the parameter value when the type is float. |
void |
setValue(float[] value)
Sets the parameter value for any type. |
void |
setValue(int value)
Sets the parameter value when the type is int. |
void |
setValue(int i,
float value)
Sets the ith value for the parameter (only valid for vec or mat types). |
void |
setValue(int i,
int j,
float value)
Sets the (ith, jth) value for the parameter (only valid for mat types). |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public GLCgShaderParameter(processing.core.PApplet parent, java.lang.String name, java.lang.String label, int type)
parent
- PAppletname
- Stringlabel
- Stringtype
- intpublic GLCgShaderParameter(processing.core.PApplet parent, GLShader shader, java.lang.String name, java.lang.String label, int type)
parent
- PAppletshader
- GLShadername
- Stringlabel
- Stringtype
- intMethod Detail |
---|
public void setProgramType(int type)
public boolean available()
public void init()
public void copyToShader()
public void setShader(GLShader shader)
shader
- GLShaderpublic void setValue(int value)
value
- intpublic void setValue(float value)
value
- floatpublic void setValue(float[] value)
value
- float[]public void setValue(int i, float value)
int
- ivalue
- floatpublic void setValue(int i, int j, float value)
int
- iint
- jvalue
- floatpublic static int getType(java.lang.String typeStr)
String
- typeStr
public int getType()
public java.lang.String getName()
public java.lang.String getLabel()
public int getArrayLength()
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |