Package com.jme3.shader
Class ShaderNode
java.lang.Object
com.jme3.shader.ShaderNode
A ShaderNode is the unit brick part of a shader program. A shader can be
 described by several shader nodes that are plugged together through inputs
 and outputs.
 A ShaderNode is based on a definition that has a shader code, inputs and
 output variables. This node can be activated based on a condition, and has
 input and output mapping.
 This class is not intended to be used by JME users directly. It's the
 structure for loading shader nodes from a J3md material definition file
- 
Constructor Summary
ConstructorsConstructorDescriptionCreates a shader node.ShaderNode(String name, ShaderNodeDefinition definition, String condition) Creates a shader node. - 
Method Summary
Modifier and TypeMethodDescriptionclone()Gets the condition.Returns the shader node definition.Returns a list of variable mapping representing the input mappings of this node.getName()Gets the name of the node.Returns a list of variable mapping representing the output mappings of this node.voidread(JmeImporter im) jme serializationvoidsetCondition(String condition) Sets the condition.voidsetDefinition(ShaderNodeDefinition definition) Sets the shader node definition.voidsetInputMapping(List<VariableMapping> inputMapping) Sets the input mappings.voidSets the name of the node.voidsetOutputMapping(List<VariableMapping> outputMapping) Sets the output mappings.toString()convenience toStringvoidwrite(JmeExporter ex) jme serialization 
- 
Constructor Details
- 
ShaderNode
Creates a shader node.- Parameters:
 name- the name.definition- the shader node definition.condition- the condition to activate this node.
 - 
ShaderNode
public ShaderNode()Creates a shader node. 
 - 
 - 
Method Details
- 
getName
Gets the name of the node.- Returns:
 - the name of the node
 
 - 
setName
Sets the name of the node.- Parameters:
 name- the name of the node.
 - 
getDefinition
Returns the shader node definition.- Returns:
 - the shader node definition.
 
 - 
setDefinition
Sets the shader node definition.- Parameters:
 definition- the shader node definition.
 - 
getCondition
Gets the condition.- Returns:
 - the condition.
 
 - 
setCondition
Sets the condition.- Parameters:
 condition- the condition.
 - 
getInputMapping
Returns a list of variable mapping representing the input mappings of this node.- Returns:
 - the input mappings.
 
 - 
setInputMapping
Sets the input mappings.- Parameters:
 inputMapping- the input mappings.
 - 
getOutputMapping
Returns a list of variable mapping representing the output mappings of this node.- Returns:
 - the output mappings.
 
 - 
setOutputMapping
Sets the output mappings.- Parameters:
 outputMapping- the output mappings.
 - 
write
jme serialization- Specified by:
 writein interfaceSavable- Parameters:
 ex- the exporter- Throws:
 IOException- from the exporter
 - 
read
jme serialization- Specified by:
 readin interfaceSavable- Parameters:
 im- the importer- Throws:
 IOException- from the importer
 - 
toString
convenience toString - 
clone
- Overrides:
 clonein classObject- Throws:
 CloneNotSupportedException
 
 -