Class FlyPathBehavior_WM.BranchState
- java.lang.Object
- 
- gov.nih.mipav.view.renderer.WildMagic.flythroughview.FlyPathBehavior_WM.BranchState
 
- 
- All Implemented Interfaces:
- java.lang.Cloneable
 - Enclosing class:
- FlyPathBehavior_WM
 
 private class FlyPathBehavior_WM.BranchState extends java.lang.Object implements java.lang.CloneableBranch information.
- 
- 
Field SummaryFields Modifier and Type Field Description float[]m_afBranchPointList of branch points (normalized path distances where one or more branches starts).booleanm_bMoveForwardCurrent direction.protected floatm_fDistUnvisitedMaxRange of normalized path distances that have not been visited.protected floatm_fDistUnvisitedMinRange of normalized path distances that have not been visited.floatm_fNormalizedPathDistCurrent position along the path.floatm_fParentBranchPointNormalized distance (in range [0,1]) along parent branch where the specified branch starts.intm_iBranchIndexIdentifies the current curve in the path graph.intm_iParentBranchIndexInformation about the parent branch, if one exists.WildMagic.LibFoundation.Curves.Curve3fm_kBranchCurveBranch curve
 - 
Constructor SummaryConstructors Constructor Description BranchState(int iBranchIndex, FlyPathGraphCurve kFlyPathGraph)Constructor.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.lang.Objectclone()Clone the current branch state.FlyPathBehavior_WM.BranchStatecreateCopy()Create a copy of this instance.FlyPathBehavior_WM.BranchStatecreateReverseCopy()Create a copy of this instance which has the same information except that the state of the moving forward is inverted.intgetBranchPointSegment(float fNormalizedPathDist)Return an index which identifies segment the specified normalized path distance belongs.WildMagic.LibFoundation.Mathematics.Vector3fgetForwardNormalizedPosition(float fDist)Return the position of the curve of the point further down the curve the specified distance in the current heading.floatgetForwardNormalizedTime(float fForwardDist)Return the normalized path distance of a point further down the branch curve in the current heading.voidstart()Reset parameters to start at the beginning of the path moving in the forward direction.voidupdateDistUnvisited(float fNewNormalizedPathDistance)Update the range of normalized path distances that have not been visited.
 
- 
- 
- 
Field Detail- 
m_afBranchPointpublic float[] m_afBranchPoint List of branch points (normalized path distances where one or more branches starts).
 - 
m_bMoveForwardpublic boolean m_bMoveForward Current direction. True if forward, false if reverse.
 - 
m_fNormalizedPathDistpublic float m_fNormalizedPathDist Current position along the path.
 - 
m_fParentBranchPointpublic float m_fParentBranchPoint Normalized distance (in range [0,1]) along parent branch where the specified branch starts.
 - 
m_iBranchIndexpublic int m_iBranchIndex Identifies the current curve in the path graph.
 - 
m_iParentBranchIndexpublic int m_iParentBranchIndex Information about the parent branch, if one exists.
 - 
m_kBranchCurvepublic WildMagic.LibFoundation.Curves.Curve3f m_kBranchCurve Branch curve
 - 
m_fDistUnvisitedMaxprotected float m_fDistUnvisitedMax Range of normalized path distances that have not been visited.
 - 
m_fDistUnvisitedMinprotected float m_fDistUnvisitedMin Range of normalized path distances that have not been visited.
 
- 
 - 
Constructor Detail- 
BranchStatepublic BranchState(int iBranchIndex, FlyPathGraphCurve kFlyPathGraph)Constructor.- Parameters:
- iBranchIndex- int Index which identifies the branch.
- kFlyPathGraph- FlyPathGraphCurve Data structure which contains all of the information about each branch and its connections.
 
 
- 
 - 
Method Detail- 
createCopypublic FlyPathBehavior_WM.BranchState createCopy() Create a copy of this instance.- Returns:
- BranchState New instance which is a copy of this instance.
 
 - 
createReverseCopypublic FlyPathBehavior_WM.BranchState createReverseCopy() Create a copy of this instance which has the same information except that the state of the moving forward is inverted.- Returns:
- BranchState New instance which is a copy of this instance except that the moving forward flag is inverted.
 
 - 
getBranchPointSegmentpublic int getBranchPointSegment(float fNormalizedPathDist) Return an index which identifies segment the specified normalized path distance belongs.- Parameters:
- fNormalizedPathDist- float Normalized path distance in the range [0,1] along the branch path.
- Returns:
- int An index of zero is returned if the distance is before the first branch point or if there are no branch points. An index of one is returned if the distance is greater than or equal to the first branch point but less than or equal to second branch point.
 
 - 
getForwardNormalizedPositionpublic WildMagic.LibFoundation.Mathematics.Vector3f getForwardNormalizedPosition(float fDist) Return the position of the curve of the point further down the curve the specified distance in the current heading.- Parameters:
- fDist- float Distance further down the branch curve in the current heading. This value can be negative for a point in the reverse heading.
- Returns:
- Point3f Coordinates of the 3D point further down along the curve.
 
 - 
getForwardNormalizedTimepublic float getForwardNormalizedTime(float fForwardDist) Return the normalized path distance of a point further down the branch curve in the current heading.- Parameters:
- fForwardDist- float Distance further down the branch curve in the current heading. This value can be negative for a point in the reverse heading.
- Returns:
- float Normalized path distance in the [0,1] range for the requested point.
 
 - 
startpublic void start() Reset parameters to start at the beginning of the path moving in the forward direction.
 - 
updateDistUnvisitedpublic void updateDistUnvisited(float fNewNormalizedPathDistance) Update the range of normalized path distances that have not been visited. Call this method before changing the current normalized path distance!- Parameters:
- fNewNormalizedPathDistance- float Normalized path distance about to be set for this branch.
 
 - 
cloneprotected java.lang.Object clone() Clone the current branch state. Used by the mouse recording process.- Overrides:
- clonein class- java.lang.Object
- Returns:
- Object
- Throws:
- java.lang.InternalError- DOCUMENT ME!
 
 
- 
 
-