public class Clip extends Leaf
View| Modifier and Type | Field and Description |
|---|---|
static int |
ALLOW_APPLICATION_BOUNDS_READ
Specifies that the Clip allows read access to its application
bounds and bounding leaf at runtime.
|
static int |
ALLOW_APPLICATION_BOUNDS_WRITE
Specifies that the Clip allows write access to its application
bounds and bounding leaf at runtime.
|
static int |
ALLOW_BACK_DISTANCE_READ
Specifies that the Clip allows read access to its back distance
at runtime.
|
static int |
ALLOW_BACK_DISTANCE_WRITE
Specifies that the Clip allows write access to its back distance
at runtime.
|
private static int[] |
readCapabilities |
ALLOW_AUTO_COMPUTE_BOUNDS_READ, ALLOW_AUTO_COMPUTE_BOUNDS_WRITE, ALLOW_BOUNDS_READ, ALLOW_BOUNDS_WRITE, ALLOW_COLLIDABLE_READ, ALLOW_COLLIDABLE_WRITE, ALLOW_LOCAL_TO_VWORLD_READ, ALLOW_LOCALE_READ, ALLOW_PARENT_READ, ALLOW_PICKABLE_READ, ALLOW_PICKABLE_WRITE, ENABLE_COLLISION_REPORTING, ENABLE_PICK_REPORTINGnodeHashtable, retained| Constructor and Description |
|---|
Clip()
Constructs a Clip node with default parameters.
|
Clip(double backDistance)
Constructs a Clip node with the specified back clip distance.
|
| Modifier and Type | Method and Description |
|---|---|
Node |
cloneNode(boolean forceDuplicate)
Used to create a new instance of the node.
|
(package private) void |
createRetained()
Creates the retained mode ClipRetained object that this
Clip component object will point to.
|
(package private) void |
duplicateAttributes(Node originalNode,
boolean forceDuplicate)
Copies all Clip information from
originalNode into
the current node. |
BoundingLeaf |
getApplicationBoundingLeaf()
Retrieves the Clip node's application bounding leaf.
|
Bounds |
getApplicationBounds()
Retrieves the Clip node's application bounds.
|
double |
getBackDistance()
Retrieves the back clip distance.
|
void |
setApplicationBoundingLeaf(BoundingLeaf region)
Set the Clip's application region to the specified bounding leaf.
|
void |
setApplicationBounds(Bounds region)
Set the Clip's application region to the specified bounds.
|
void |
setBackDistance(double backDistance)
Sets the back clip distance to the specified value.
|
void |
updateNodeReferences(NodeReferenceTable referenceTable)
Callback used to allow a node to check if any scene graph objects
referenced
by that node have been duplicated via a call to
cloneTree. |
checkDuplicateNode, checkForCycle, cloneTree, cloneTree, cloneTree, cloneTree, cloneTree, cloneTree, cloneTree, duplicateNode, getBounds, getBoundsAutoCompute, getCollidable, getLocale, getLocalToVworld, getLocalToVworld, getParent, getPickable, setBounds, setBoundsAutoCompute, setCollidable, setPickablecapabilityBitsEmpty, checkForLiveOrCompiled, clearCapability, clearCapabilityIsFrequent, clearLive, duplicateSceneGraphObject, getCapability, getCapabilityIsFrequent, getName, getNamePrefix, getNodeComponent, getUserData, isCompiled, isLive, isLiveOrCompiled, setCapability, setCapabilityIsFrequent, setCompiled, setDefaultReadCapabilities, setLive, setName, setUserData, toStringpublic static final int ALLOW_APPLICATION_BOUNDS_READ
public static final int ALLOW_APPLICATION_BOUNDS_WRITE
public static final int ALLOW_BACK_DISTANCE_READ
public static final int ALLOW_BACK_DISTANCE_WRITE
private static final int[] readCapabilities
public Clip()
public Clip(double backDistance)
public void setBackDistance(double backDistance)
backDistance - the new back clip distance in metersView.setFrontClipDistance(double),
View.setBackClipDistance(double)public double getBackDistance()
public void setApplicationBounds(Bounds region)
region - the bounds that contains the Clip's new application
region.CapabilityNotSetException - if appropriate capability is
not set and this object is part of live or compiled scene graphpublic Bounds getApplicationBounds()
CapabilityNotSetException - if appropriate capability is
not set and this object is part of live or compiled scene graphpublic void setApplicationBoundingLeaf(BoundingLeaf region)
region - the bounding leaf node used to specify the Clip
node's new application region.CapabilityNotSetException - if appropriate capability is
not set and this object is part of live or compiled scene graphpublic BoundingLeaf getApplicationBoundingLeaf()
CapabilityNotSetException - if appropriate capability is
not set and this object is part of live or compiled scene graphvoid createRetained()
createRetained in class SceneGraphObjectpublic Node cloneNode(boolean forceDuplicate)
cloneTree to duplicate the current node.cloneNode in class NodeforceDuplicate - when set to true, causes the
duplicateOnCloneTree flag to be ignored. When
false, the value of each node's
duplicateOnCloneTree variable determines whether
NodeComponent data is duplicated or copied.Node.cloneTree(),
Node.cloneNode(boolean),
Node.duplicateNode(javax.media.j3d.Node, boolean),
NodeComponent.setDuplicateOnCloneTree(boolean)public void updateNodeReferences(NodeReferenceTable referenceTable)
cloneTree.
This method is called by cloneTree after all nodes in
the sub-graph have been duplicated. The cloned Leaf node's method
will be called and the Leaf node can then look up any object references
by using the getNewObjectReference method found in the
NodeReferenceTable object. If a match is found, a
reference to the corresponding object in the newly cloned sub-graph
is returned. If no corresponding reference is found, either a
DanglingReferenceException is thrown or a reference to the original
object is returned depending on the value of the
allowDanglingReferences parameter passed in the
cloneTree call.
NOTE: Applications should not call this method directly. It should only be called by the cloneTree method.
updateNodeReferences in class SceneGraphObjectreferenceTable - a NodeReferenceTableObject that contains the
getNewObjectReference method needed to search for
new object instances.NodeReferenceTable,
Node.cloneTree(),
DanglingReferenceExceptionvoid duplicateAttributes(Node originalNode, boolean forceDuplicate)
originalNode into
the current node. This method is called from the
cloneNode method which is, in turn, called by the
cloneTree method.duplicateAttributes in class NodeoriginalNode - the original node to duplicate.forceDuplicate - when set to true, causes the
duplicateOnCloneTree flag to be ignored. When
false, the value of each node's
duplicateOnCloneTree variable determines whether
NodeComponent data is duplicated or copied.RestrictedAccessException - if this object is part of a live
or compiled scenegraph.Node.duplicateNode(javax.media.j3d.Node, boolean),
Node.cloneTree(),
NodeComponent.setDuplicateOnCloneTree(boolean)Copyright 1996-2008 Sun Microsystems, Inc. All Rights Reserved. Use is subject to license terms.