public class InstancedNode extends GeometryGroupNode
Spatial.BatchHint, Spatial.CullHint, Spatial.DFSMode
Modifier and Type | Field and Description |
---|---|
protected java.util.HashMap<Geometry,InstancedGeometry> |
igByGeom |
batchHint, controls, cullHint, frustrumIntersects, key, localLights, localOverrides, localTransform, name, parent, queueBucket, queueDistance, refreshFlags, RF_BOUND, RF_CHILD_LIGHTLIST, RF_LIGHTLIST, RF_MATPARAM_OVERRIDE, RF_TRANSFORM, shadowMode, userData, worldBound, worldLights, worldOverrides, worldTransform
Modifier | Constructor and Description |
---|---|
protected |
InstancedNode()
Serialization only.
|
|
InstancedNode(java.lang.String name) |
Modifier and Type | Method and Description |
---|---|
Node |
clone()
Creates a clone of the asset.
|
Node |
clone(boolean cloneMaterials) |
void |
cloneFields(Cloner cloner,
java.lang.Object original)
Called internally by com.jme3.util.clone.Cloner.
|
Spatial |
detachChildAt(int index)
detachChildAt removes a child at a given index. |
void |
instance() |
void |
onGeometryUnassociated(Geometry geom)
Called by
geom to specify that it
has been unassociated from its GeoemtryGroupNode . |
void |
onMaterialChange(Geometry geom)
|
void |
onMeshChange(Geometry geom)
|
void |
onTransformChange(Geometry geom)
Called by
geom to specify that its world transform
has been changed. |
getGeometryStartIndex, setGeometryStartIndex
attachChild, attachChildAt, breadthFirstTraversal, collideWith, deepClone, depthFirstTraversal, descendantMatches, descendantMatches, descendantMatches, detachAllChildren, detachChild, detachChildNamed, getChild, getChild, getChildIndex, getChildren, getQuantity, getTriangleCount, getVertexCount, hasChild, oldDeepClone, read, setLightListRefresh, setLodLevel, setMaterial, setMatParamOverrideRefresh, setModelBound, setParent, setTransformRefresh, swapChildren, updateGeometricState, updateLogicalState, updateModelBound, updateWorldBound, write
addControl, addLight, addMatParamOverride, breadthFirstTraversal, center, checkCulling, clearMatParamOverrides, depthFirstTraversal, forceRefresh, getBatchHint, getControl, getControl, getCullHint, getKey, getLastFrustumIntersection, getLocalBatchHint, getLocalCullHint, getLocalLightList, getLocalMatParamOverrides, getLocalQueueBucket, getLocalRotation, getLocalScale, getLocalShadowMode, getLocalToWorldMatrix, getLocalTransform, getLocalTranslation, getName, getNumControls, getParent, getQueueBucket, getShadowMode, getUserData, getUserDataKeys, getWorldBound, getWorldLightList, getWorldMatParamOverrides, getWorldRotation, getWorldScale, getWorldTransform, getWorldTranslation, hasAncestor, jmeClone, localToWorld, lookAt, matches, move, move, oldClone, removeControl, removeControl, removeFromParent, removeLight, removeMatParamOverride, rotate, rotate, rotateUpTo, runControlRender, scale, scale, setBatchHint, setBoundRefresh, setCullHint, setKey, setLastFrustumIntersection, setLocalRotation, setLocalRotation, setLocalScale, setLocalScale, setLocalScale, setLocalTransform, setLocalTranslation, setLocalTranslation, setName, setQueueBucket, setRequiresUpdates, setShadowMode, setUserData, toString, updateMatParamOverrides, updateWorldLightList, updateWorldTransforms, worldToLocal
protected java.util.HashMap<Geometry,InstancedGeometry> igByGeom
protected InstancedNode()
public InstancedNode(java.lang.String name)
public Spatial detachChildAt(int index)
Node
detachChildAt
removes a child at a given index. That child
is returned for saving purposes.detachChildAt
in class Node
index
- the index of the child to be removed.public void instance()
public Node clone()
CloneableSmartAsset
Object.clone()
for more info on how this method
should be implemented.clone
in interface CloneableSmartAsset
clone
in class Spatial
Mesh.cloneForAnim()
public Node clone(boolean cloneMaterials)
clone
in class Node
cloneMaterials
- true to clone materials, false to share themMesh.cloneForAnim()
public void cloneFields(Cloner cloner, java.lang.Object original)
cloneFields
in interface JmeCloneable
cloneFields
in class Node
cloner
- The cloner that is performing the cloning operation. The
cloneFields method can call back into the cloner to make
clones of its subordinate fields.original
- The original object from which this object was cloned.
This is provided for the very rare case that this object needs
to refer to its original for some reason. In general, all of
the relevant values should have been transferred during the
shallow clone and this object need merely clone what it wants.public void onTransformChange(Geometry geom)
GeometryGroupNode
geom
to specify that its world transform
has been changed.onTransformChange
in class GeometryGroupNode
geom
- The Geometry whose transform changed.public void onMaterialChange(Geometry geom)
GeometryGroupNode
onMaterialChange
in class GeometryGroupNode
geom
- The Geometry whose material changed.public void onMeshChange(Geometry geom)
GeometryGroupNode
geom
to specify that its
mesh
has been changed.
This is also called when the geometry's
lod level
changes.onMeshChange
in class GeometryGroupNode
geom
- The Geometry whose mesh changed.public void onGeometryUnassociated(Geometry geom)
GeometryGroupNode
geom
to specify that it
has been unassociated from its GeoemtryGroupNode
.
Unassociation occurs when the Geometry
is
detached
from its parent
Node
.onGeometryUnassociated
in class GeometryGroupNode
geom
- The Geometry which is being unassociated.