|
Xj3D VRML/X3D Code API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.web3d.vrml.renderer.common.nodes.AbstractNode
org.web3d.vrml.renderer.common.nodes.BaseComponentGeometryNode
org.web3d.vrml.renderer.common.nodes.BaseIndexedTriangleGeometryNode
An abstract implementation of the IndexedTriangle* nodes.
| Field Summary | |
protected static java.lang.String |
COLOR_NODE_MSG
Message for when the node in setValue() is not a Color |
protected static java.lang.String |
COLOR_PROTO_MSG
Message for when the proto is not a Color |
protected static java.lang.String |
COORD_NODE_MSG
Message for when the node in setValue() is not a Coord |
protected static java.lang.String |
COORD_PROTO_MSG
Message for when the proto is not a Coord |
protected static int |
FIELD_INDEX
Index of the index MFInt32 field |
protected static int |
FIELD_SET_INDEX
Index of the set_colorIndex MFInt32 eventIn |
protected org.j3d.geom.GeometryData |
geomData
Userdata kept in the triangle geometry |
protected static int |
LAST_INDEXEDTRIANGLEGEOMETRY_INDEX
The last field index used by this class |
protected static java.lang.String |
NORMAL_NODE_MSG
Message for when the node in setValue() is not a Normal |
protected static java.lang.String |
NORMAL_PROTO_MSG
Message for when the proto is not a Normal |
protected int |
numIndex
Number of valid values in vfIndex |
protected static java.lang.String |
TEXCOORD_NODE_MSG
Message for when the node in setValue() is not a TexCoord |
protected static java.lang.String |
TEXCOORD_PROTO_MSG
Message for when the proto is not a TexCoord |
protected int[] |
vfIndex
field MFInt32 index |
| Fields inherited from class org.web3d.vrml.renderer.common.nodes.AbstractNode |
errorReporter, FIELD_METADATA, fieldData, hasChanged, INIT_ONLY_WRITE_MSG, inSetup, isDEF, isStatic, LAST_NODE_INDEX, METADATA_NODE_MSG, METADATA_PROTO_MSG, nodeName, pMetadata, refCount, stateManager, vfMetadata, vrmlMajorVersion, vrmlMinorVersion |
| Constructor Summary | |
protected |
BaseIndexedTriangleGeometryNode(java.lang.String name)
Construct a default instance of this class with the bind flag set to false and no time information set (effective value of zero). |
| Method Summary | |
void |
allEventsComplete()
Notification that the rendering of the event model is complete and that rendering is about to begin. |
protected abstract void |
buildImpl()
Build the render specific implementation. |
protected void |
copy(VRMLComponentGeometryNodeType node)
Set the fields of the binadble node that has the fields set based on the fields of the passed in node. |
void |
fieldChanged(VRMLNodeType node,
int index)
Notification that the field from the node has changed. |
VRMLFieldData |
getFieldValue(int index)
Get the value of a field. |
void |
notifyExternProtoLoaded(int index,
VRMLNodeType node)
Notify a node that an ExternProto has resolved. |
void |
sendRoute(double time,
int srcIndex,
VRMLNodeType destNode,
int destIndex)
Send a routed value from this node to the given destination node. |
protected void |
setColorNode(VRMLColorNodeType node)
Notification of the color node being set. |
protected void |
setCoordinateNode(VRMLCoordinateNodeType node)
Notification of the coordinate node being set. |
protected void |
setIndex(int[] value,
int numValid)
Set the index field. |
protected void |
setNormalNode(VRMLNormalNodeType node)
Notification of the color node being set. |
protected void |
setTextureCoordinateNode(VRMLTextureCoordinateNodeType node)
Notification of the coordinate node being set. |
void |
setupFinished()
Notification that the construction phase of this node has finished. |
void |
setValue(int index,
int[] value,
int numValid)
Set the value of the field at the given index as an array of integers. |
void |
setValue(int index,
VRMLNodeType child)
Set the value of the field at the given index as a node. |
protected void |
updateColorArray()
Update the normal array in geomData based on the normal node and normalPerVertex flag. |
protected void |
updateCoordinateArray()
Update the coordinate array in geomData based on the coordinate data. |
protected void |
updateNormalArray()
Update the normal array in geomData based on the normal node and normalPerVertex flag. |
| Methods inherited from class org.web3d.vrml.renderer.common.nodes.BaseComponentGeometryNode |
addLocalColorsListener, addTexCoordGenModeChanged, fireLocalColorsChanged, getComponents, getNumSets, getPrimaryType, getTexCoordGenMode, hasColorPerVertex, hasLocalColors, hasNormalPerVertex, isCCW, isLightingEnabled, isSolid, removeLocalColorsListener, removeTexCoordGenModeChanged, setComponent, setComponents, setFogCoordinateNode, setTexCoordNode, setValue |
| Methods inherited from class org.web3d.vrml.renderer.common.nodes.AbstractNode |
addNodeListener, checkNodeType, checkSecondaryType, checkSecondaryType, fireFieldChanged, getMetadataObject, getNodeFieldIndices, getRefCount, getSecondaryType, getUserData, getVRMLNodeName, hasFieldChanged, isDEF, isSetupFinished, removeNodeListener, setDEF, setErrorReporter, setFrameStateManager, setMetadataObject, setUserData, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setVersion, updateRefCount |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.web3d.vrml.nodes.VRMLNodeType |
addNodeListener, getMetadataObject, getRefCount, hasFieldChanged, isSetupFinished, removeNodeListener, setDEF, setFrameStateManager, setMetadataObject, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, updateRefCount |
| Methods inherited from interface org.web3d.vrml.lang.VRMLNode |
getFieldDeclaration, getFieldIndex, getNodeFieldIndices, getNumFields, getSecondaryType, getUserData, getVRMLNodeName, isDEF, setErrorReporter, setUserData, setVersion |
| Field Detail |
protected static final int FIELD_INDEX
protected static final int FIELD_SET_INDEX
protected static final int LAST_INDEXEDTRIANGLEGEOMETRY_INDEX
protected static final java.lang.String COORD_PROTO_MSG
protected static final java.lang.String COORD_NODE_MSG
protected static final java.lang.String COLOR_PROTO_MSG
protected static final java.lang.String COLOR_NODE_MSG
protected static final java.lang.String NORMAL_PROTO_MSG
protected static final java.lang.String NORMAL_NODE_MSG
protected static final java.lang.String TEXCOORD_PROTO_MSG
protected static final java.lang.String TEXCOORD_NODE_MSG
protected int[] vfIndex
protected int numIndex
protected org.j3d.geom.GeometryData geomData
| Constructor Detail |
protected BaseIndexedTriangleGeometryNode(java.lang.String name)
name - The name of the type of node| Method Detail |
protected void copy(VRMLComponentGeometryNodeType node)
copy in class BaseComponentGeometryNodenode - The bindable node to copy info fromprotected abstract void buildImpl()
public void allEventsComplete()
allEventsComplete in interface FrameStateListenerallEventsComplete in class AbstractNode
public VRMLFieldData getFieldValue(int index)
throws InvalidFieldException
getFieldValue in interface VRMLNodeTypegetFieldValue in class BaseComponentGeometryNodeindex - The index of the field to change.
InvalidFieldException - The field index is not known
public void sendRoute(double time,
int srcIndex,
VRMLNodeType destNode,
int destIndex)
sendRoute in interface VRMLNodeTypesendRoute in class BaseComponentGeometryNodetime - The time that this route occurred (not necessarily epoch
time. Should be treated as a relative value only)srcIndex - The index of the field in this node that the value
should be sent fromdestNode - The node reference that we will be sending the value todestIndex - The index of the field in the destination node that
the value should be sent to.
public void setValue(int index,
int[] value,
int numValid)
throws InvalidFieldException,
InvalidFieldValueException,
InvalidFieldAccessException
setValue in interface VRMLNodeTypesetValue in class AbstractNodeindex - The index of destination field to setvalue - The new value to use for the nodenumValid - The number of valid values to copy from the array
InvalidFieldException - The index does not match a known field
InvalidFieldValueException - The value provided is out of range
for the field type.
InvalidFieldAccessException - The call is attempting to write to
a field that does not permit writing nowpublic void setupFinished()
setupFinished in interface VRMLNodeTypesetupFinished in class BaseComponentGeometryNode
public void notifyExternProtoLoaded(int index,
VRMLNodeType node)
throws InvalidFieldValueException
notifyExternProtoLoaded in interface VRMLNodeTypenotifyExternProtoLoaded in class AbstractNodeindex - The field index
InvalidFieldValueException - If the proto contains he wrong type
public void setValue(int index,
VRMLNodeType child)
throws InvalidFieldException,
InvalidFieldValueException
setValue in interface VRMLNodeTypesetValue in class BaseComponentGeometryNodeindex - The index of destination field to setchild - The new value to use for the node
InvalidFieldException - The field index is not known
InvalidFieldValueException - The node does not match the required
type.protected void setCoordinateNode(VRMLCoordinateNodeType node)
setCoordinateNode in class BaseComponentGeometryNodenode - The node to useprotected void setColorNode(VRMLColorNodeType node)
setColorNode in class BaseComponentGeometryNodenode - The node to useprotected void setTextureCoordinateNode(VRMLTextureCoordinateNodeType node)
node - The node to useprotected void setNormalNode(VRMLNormalNodeType node)
setNormalNode in class BaseComponentGeometryNodenode - The node to use
public void fieldChanged(VRMLNodeType node,
int index)
node - The component node that changedindex - The index of the field that has changed
protected void setIndex(int[] value,
int numValid)
value - The list of index values to usenumValid - The number of valid values to copy from the arrayprotected void updateCoordinateArray()
protected void updateNormalArray()
protected void updateColorArray()
|
Xj3D VRML/X3D Code API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||