javax.media.j3d
Class TransformGroupRetained

java.lang.Object
  extended by javax.media.j3d.IndexedObject
      extended by javax.media.j3d.SceneGraphObjectRetained
          extended by javax.media.j3d.NodeRetained
              extended by javax.media.j3d.GroupRetained
                  extended by javax.media.j3d.TransformGroupRetained
All Implemented Interfaces:
java.lang.Cloneable, BHLeafInterface, NnuId, TargetsInterface

 class TransformGroupRetained
extends GroupRetained
implements TargetsInterface

Group node that contains a transform.


Field Summary
(package private)  boolean aboveAViewPlatform
           
(package private)  CachedTargets[] cachedTargets
           
(package private)  Transform3D[][] childLocalToVworld
          localVworld values for children of this TG
(package private)  int[][] childLocalToVworldIndex
           
(package private)  Transform3D[][] childTrans
           
(package private)  java.util.ArrayList childTransformLinks
           
(package private)  int[][] childTransIndex
           
(package private)  HashKey currentKey
           
(package private)  Transform3D currentTransform
          The Transform value currently being used internally
(package private)  Transform3D invTransform
          The inverse of the transform
(package private)  CachedTargets[] j3dCTs
           
(package private)  int localTargetThreads
          A bitmask of the types in targets
(package private)  int maxTransformLevel
           
(package private)  boolean needNormalsTransform
           
(package private)  Transform3D normalTransform
          The transpose of the inverse of the transform
(package private)  TransformGroupData[] perPathData
           
(package private)  int targetThreads
           
(package private)  Transform3D transform
          The Transform value for the TransformGroup.
(package private)  WakeupIndexedList transformChange
          A list of WakeupOnTransformChange conditions for this Transform
(package private)  int[] transformLevels
           
 
Fields inherited from class javax.media.j3d.GroupRetained
allocatedAltApps, allocatedFogs, allocatedLights, allocatedMclips, altAppearances, bhLeafNode, children, childrenSwitchLinks, collisionBound, collisionTarget, collisionVwcBounds, compiledChildrenList, fogs, inViewSpecificGroup, isInClearLive, isRoot, key, lights, locale, mirrorGroup, modelClips, orderedPaths, parentSwitchLinkChildIndex, scopingRefCount, sourceNode, viewLists
 
Fields inherited from class javax.media.j3d.NodeRetained
ALTERNATEAPPEARANCE, AMBIENTLIGHT, apiBounds, BACKGROUND, BACKGROUNDSOUND, BEHAVIOR, BOUNDINGLEAF, boundsAutoCompute, BRANCHGROUP, branchGroupPaths, cachedBounds, childIndex, CLIP, collidable, CONESOUND, CONTAINS_VIEWPLATFORM, CURRENT_LOCAL_TO_VWORLD, DECALGROUP, DIRECTIONALLIGHT, EXPONENTIALFOG, geometryBackground, GROUP, inSharedGroup, LAST_LOCAL_TO_VWORLD, LINEARFOG, LINK, localBounds, localToVworld, localToVworldIndex, localToVworldKeys, MODELCLIP, MORPH, nnuId, nodeId, nodeType, NUMNODES, ORDEREDGROUP, orderedId, ORIENTEDSHAPE3D, parent, parentSwitchLink, parentTransformLink, pickable, POINTLIGHT, POINTSOUND, refCount, SHAPE, SHAREDGROUP, SOUNDSCAPE, SPOTLIGHT, staticTransform, SWITCH, TRANSFORMGROUP, universe, validCachedBounds, VIEWPLATFORM, VIEWSPECIFICGROUP
 
Fields inherited from class javax.media.j3d.SceneGraphObjectRetained
DONT_MERGE, inBackgroundGroup, inSetLive, MERGE, MERGE_DONE, mergeFlag, onUpdateList, source
 
Fields inherited from class javax.media.j3d.IndexedObject
listIdx
 
Fields inherited from interface javax.media.j3d.TargetsInterface
SWITCH_TARGETS, TRANSFORM_TARGETS
 
Constructor Summary
TransformGroupRetained()
          The constructor
 
Method Summary
(package private)  void addCondition(WakeupOnTransformChange wakeup)
           
(package private)  void childCheckSetLive(NodeRetained child, int childIndex, SetLiveState s, NodeRetained linkNode)
           
(package private)  void clearLive(SetLiveState s)
          This version of clearLive calls clearLive on all of its chidren.
(package private)  void compile(CompileState compState)
          This is the default compile() method, which just marks the sgo as compiled.
(package private)  void computeCombineBounds(Bounds bounds)
          ONLY needed for SHAPE, MORPH, and LINK node type.
 void computeTargetThreads(int type, CachedTargets[] newCachedTargets)
           
 void copyCachedTargets(int type, CachedTargets[] newCt)
           
 CachedTargets getCachedTargets(int type, int index, int child)
           
(package private)  TargetsInterface getClosestTargetsInterface(int type)
           
(package private)  Transform3D getCurrentChildLocalToVworld()
          Get the current child localToVworld transform for a node
(package private)  Transform3D getCurrentChildLocalToVworld(HashKey key)
           
(package private)  Transform3D getCurrentChildLocalToVworld(int index)
           
(package private)  Transform3D getInvTransform()
           
(package private)  Transform3D getLastChildLocalToVworld(HashKey key)
          Get the last child localToVworld transform for a node
(package private)  Transform3D getNormalTransform()
           
 java.util.ArrayList getTargetsData(int type, int index)
           
 int getTargetThreads(int type)
           
(package private)  void getTransform(Transform3D t1)
          Copies the transform component of this TransformGroup into the passed transform object.
(package private)  Transform3D getUpdateChildLocalToVworld(int index)
          get the to be updated child localToVworld
(package private)  boolean isStatic()
          true if component can't be read or written after compile or setlive()
(package private)  void merge(CompileState compState)
           
(package private)  void mergeTransform(TransformGroupRetained xform)
           
(package private)  void notifyConditions()
           
(package private)  void processChildLocalToVworld(java.util.ArrayList dirtyTransformGroups, java.util.ArrayList keySet, UpdateTargets targets, java.util.ArrayList blUsers)
           
 void propagateTargetThreads(int type, int childTargetThreads)
           
(package private)  void removeCondition(WakeupOnTransformChange wakeup)
           
(package private)  void removeNodeData(SetLiveState s)
          remove the localToVworld transform for a transformGroup
 void resetCachedTargets(int type, CachedTargets[] newCtArr, int child)
           
(package private)  void setAuxData(SetLiveState s, int index, int hkIndex)
           
(package private)  void setLive(SetLiveState s)
          This setlive simply concatinates it's transform onto all the ones passed in.
(package private)  void setNodeData(SetLiveState s)
           
(package private)  void setTransform(Transform3D t1)
          Sets the transform component of this TransformGroup to the value of the passed transform.
(package private)  void transformBounds(SceneGraphPath path, Bounds bound)
          Transform the input bound by the current LocalToVWorld, this one overwrite the one defined in NodeRetained since for TransformGroup, it has to use currentChildLocalToVworld instead of currentLocalToVworld
(package private)  void traverse(boolean sameLevel, int level)
           
 void updateCachedTargets(int type, CachedTargets[] newCt)
           
(package private)  void updateChildLocalToVworld(java.util.ArrayList dirtyTransformGroups, java.util.ArrayList keySet, UpdateTargets targets, java.util.ArrayList blUsers)
           
(package private)  void updateChildLocalToVworld(HashKey key, int index, java.util.ArrayList dirtyTransformGroups, java.util.ArrayList keySet, UpdateTargets targets, java.util.ArrayList blUsers)
           
 void updateTargetThreads(int type, CachedTargets[] newCachedTargets)
           
 
Methods inherited from class javax.media.j3d.GroupRetained
addAllNodesForScopedAltApp, addAllNodesForScopedFog, addAllNodesForScopedLight, addAllNodesForScopedModelClip, addAltApp, addChild, addFog, addLight, addModelClip, appendChildrenData, checkClearLive, checkClearLive, checkSetLive, checkSetLive, checkValidChild, childDoSetLive, computeBoundingHull, createMirrorGroup, doAddChild, doInsertChild, doMoveTo, doRemoveChild, doSetChild, doSetLive, findSwitchInfo, gatherBlUsers, getAllChildren, getAlternateCollisionTarget, getBounds, getChild, getCollisionBounds, getEffectiveBounds, getLocale2, indexOfChild, initSwitchStates, initTransformStates, insertChild, insertChildrenData, isEnable, isEnable, isNodeSwitchOn, isStaticChildren, moveTo, numChildren, processAddNodesForScopedAltApp, processAddNodesForScopedFog, processAddNodesForScopedModelClip, processAllNodesForScopedLight, processCollisionTarget, processRemoveAllNodesForScopedFog, processRemoveAllNodesForScopedLight, processRemoveAllNodesForScopedModelClip, processRemoveNodesForScopedAltApp, processViewSpecificInfo, removeAllChildren, removeAllNodesForScopedAltApp, removeAllNodesForScopedFog, removeAllNodesForScopedLight, removeAllNodesForScopedModelClip, removeAltApp, removeAltAppScope, removeChild, removeChild, removeChildrenData, removeFog, removeFogScope, removeLight, removeLightScope, removeMclipScope, removeModelClip, searchGeometryAtoms, setAltAppScope, setAlternateCollisionTarget, setBounds, setBoundsAutoCompute, setChild, setCollisionBounds, setCompiled, setFogScope, setLightScope, setMclipScope, setScopingInfo, updateCollidable, updateLocalToVworld, updatePickable, updateSwitchStates, updateTransformStates, usedInScoping, validSwitchChild
 
Methods inherited from class javax.media.j3d.NodeRetained
computeNonLiveLocalToVworld, dirtyBoundsCache, equal, findCollidableFlags, findPickableFlags, findTransformLevels, getBoundsAutoCompute, getCollidable, getCurrentLocalToVworld, getCurrentLocalToVworld, getCurrentLocalToVworld, getId, getLastLocalToVworld, getLastLocalToVworld, getLastLocalToVworld, getLocalBounds, getLocale, getLocalToVworld, getLocalToVworld, getLocalToVworld, getParent, getPickable, getVirtualUniverse, notifySceneGraphChanged, recombineAbove, setCollidable, setParent, setPickable
 
Methods inherited from class javax.media.j3d.SceneGraphObjectRetained
clearLive, clearLive, clone, doSetLive, getSource, handleFrequencyChange, isInSetLive, markAsLive, setLive, setSource
 
Methods inherited from class javax.media.j3d.IndexedObject
getIdxUsed, incIdxUsed
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

transform

Transform3D transform
The Transform value for the TransformGroup.


invTransform

Transform3D invTransform
The inverse of the transform


normalTransform

Transform3D normalTransform
The transpose of the inverse of the transform


currentTransform

Transform3D currentTransform
The Transform value currently being used internally


childLocalToVworld

Transform3D[][] childLocalToVworld
localVworld values for children of this TG


childLocalToVworldIndex

int[][] childLocalToVworldIndex

childTrans

Transform3D[][] childTrans

childTransIndex

int[][] childTransIndex

localTargetThreads

int localTargetThreads
A bitmask of the types in targets


targetThreads

int targetThreads

transformChange

WakeupIndexedList transformChange
A list of WakeupOnTransformChange conditions for this Transform


childTransformLinks

java.util.ArrayList childTransformLinks

needNormalsTransform

boolean needNormalsTransform

currentKey

HashKey currentKey

aboveAViewPlatform

boolean aboveAViewPlatform

maxTransformLevel

int maxTransformLevel

transformLevels

int[] transformLevels

j3dCTs

CachedTargets[] j3dCTs

cachedTargets

CachedTargets[] cachedTargets

perPathData

TransformGroupData[] perPathData
Constructor Detail

TransformGroupRetained

TransformGroupRetained()
The constructor

Method Detail

setTransform

void setTransform(Transform3D t1)
Sets the transform component of this TransformGroup to the value of the passed transform.

Parameters:
t1 - the transform to be copied

getTransform

void getTransform(Transform3D t1)
Copies the transform component of this TransformGroup into the passed transform object.

Parameters:
t1 - the transform object to be copied into

getInvTransform

Transform3D getInvTransform()

getNormalTransform

Transform3D getNormalTransform()

setNodeData

void setNodeData(SetLiveState s)
Overrides:
setNodeData in class GroupRetained

setAuxData

void setAuxData(SetLiveState s,
                int index,
                int hkIndex)
Overrides:
setAuxData in class NodeRetained

removeCondition

void removeCondition(WakeupOnTransformChange wakeup)

addCondition

void addCondition(WakeupOnTransformChange wakeup)

notifyConditions

void notifyConditions()

isStatic

boolean isStatic()
Description copied from class: SceneGraphObjectRetained
true if component can't be read or written after compile or setlive()

Overrides:
isStatic in class GroupRetained

mergeTransform

void mergeTransform(TransformGroupRetained xform)
Overrides:
mergeTransform in class NodeRetained

traverse

void traverse(boolean sameLevel,
              int level)
Overrides:
traverse in class GroupRetained

compile

void compile(CompileState compState)
Description copied from class: SceneGraphObjectRetained
This is the default compile() method, which just marks the sgo as compiled.

Overrides:
compile in class GroupRetained

merge

void merge(CompileState compState)
Overrides:
merge in class GroupRetained

setLive

void setLive(SetLiveState s)
This setlive simply concatinates it's transform onto all the ones passed in.

Overrides:
setLive in class GroupRetained

removeNodeData

void removeNodeData(SetLiveState s)
remove the localToVworld transform for a transformGroup

Overrides:
removeNodeData in class GroupRetained

clearLive

void clearLive(SetLiveState s)
Description copied from class: GroupRetained
This version of clearLive calls clearLive on all of its chidren.

Overrides:
clearLive in class GroupRetained

computeCombineBounds

void computeCombineBounds(Bounds bounds)
Description copied from class: NodeRetained
ONLY needed for SHAPE, MORPH, and LINK node type. Compute the combine bounds of bounds and its localBounds.

Overrides:
computeCombineBounds in class GroupRetained

processChildLocalToVworld

void processChildLocalToVworld(java.util.ArrayList dirtyTransformGroups,
                               java.util.ArrayList keySet,
                               UpdateTargets targets,
                               java.util.ArrayList blUsers)

updateChildLocalToVworld

void updateChildLocalToVworld(HashKey key,
                              int index,
                              java.util.ArrayList dirtyTransformGroups,
                              java.util.ArrayList keySet,
                              UpdateTargets targets,
                              java.util.ArrayList blUsers)

updateChildLocalToVworld

void updateChildLocalToVworld(java.util.ArrayList dirtyTransformGroups,
                              java.util.ArrayList keySet,
                              UpdateTargets targets,
                              java.util.ArrayList blUsers)

transformBounds

void transformBounds(SceneGraphPath path,
                     Bounds bound)
Transform the input bound by the current LocalToVWorld, this one overwrite the one defined in NodeRetained since for TransformGroup, it has to use currentChildLocalToVworld instead of currentLocalToVworld

Overrides:
transformBounds in class NodeRetained

getUpdateChildLocalToVworld

Transform3D getUpdateChildLocalToVworld(int index)
get the to be updated child localToVworld


getCurrentChildLocalToVworld

Transform3D getCurrentChildLocalToVworld()
Get the current child localToVworld transform for a node


getCurrentChildLocalToVworld

Transform3D getCurrentChildLocalToVworld(int index)

getCurrentChildLocalToVworld

Transform3D getCurrentChildLocalToVworld(HashKey key)

getLastChildLocalToVworld

Transform3D getLastChildLocalToVworld(HashKey key)
Get the last child localToVworld transform for a node


getTargetThreads

public int getTargetThreads(int type)
Specified by:
getTargetThreads in interface TargetsInterface

getCachedTargets

public CachedTargets getCachedTargets(int type,
                                      int index,
                                      int child)
Specified by:
getCachedTargets in interface TargetsInterface

getClosestTargetsInterface

TargetsInterface getClosestTargetsInterface(int type)
Overrides:
getClosestTargetsInterface in class GroupRetained

computeTargetThreads

public void computeTargetThreads(int type,
                                 CachedTargets[] newCachedTargets)
Specified by:
computeTargetThreads in interface TargetsInterface

updateTargetThreads

public void updateTargetThreads(int type,
                                CachedTargets[] newCachedTargets)
Specified by:
updateTargetThreads in interface TargetsInterface

propagateTargetThreads

public void propagateTargetThreads(int type,
                                   int childTargetThreads)
Specified by:
propagateTargetThreads in interface TargetsInterface

updateCachedTargets

public void updateCachedTargets(int type,
                                CachedTargets[] newCt)
Specified by:
updateCachedTargets in interface TargetsInterface

copyCachedTargets

public void copyCachedTargets(int type,
                              CachedTargets[] newCt)
Specified by:
copyCachedTargets in interface TargetsInterface

resetCachedTargets

public void resetCachedTargets(int type,
                               CachedTargets[] newCtArr,
                               int child)
Specified by:
resetCachedTargets in interface TargetsInterface

getTargetsData

public java.util.ArrayList getTargetsData(int type,
                                          int index)
Specified by:
getTargetsData in interface TargetsInterface

childCheckSetLive

void childCheckSetLive(NodeRetained child,
                       int childIndex,
                       SetLiveState s,
                       NodeRetained linkNode)
Overrides:
childCheckSetLive in class GroupRetained


Copyright 1996-2008 Sun Microsystems, Inc. All Rights Reserved. Use is subject to license terms.