public class TrajectoryManager extends Object
Modifier and Type | Field and Description |
---|---|
static int |
CYLINDER |
static int |
DEFORM_RIBBON |
static boolean |
doStartOffset |
static int |
LINE |
static int[] |
o_i |
static int[] |
o_j |
static int |
POINT |
static String |
PPOP_TRAJECTORY_START_POINTS_FILE |
static String |
PROP_TRAJECTORY_PARAM_FILE_1 |
static String |
PROP_TRAJECTORY_PARAM_FILE_2 |
static String |
PROP_TRAJECTORY_TERRAIN_FILE |
static HashMap<ScalarMap,ScalarMapListener> |
removeListeners |
static int |
RIBBON |
static HashMap<FlowControl,ControlListener> |
scaleChangeListeners |
Constructor and Description |
---|
TrajectoryManager(DataRenderer renderer,
TrajectoryParams trajParams,
ArrayList<FlowInfo> flowInfoList,
int dataDomainLength,
double time) |
TrajectoryManager(DataRenderer renderer,
TrajectoryParams trajParams,
ArrayList<FlowInfo> flowInfoList,
int dataDomainLength,
double time,
ScalarMap altToZ,
CoordinateSystem dspCoordSys) |
Modifier and Type | Method and Description |
---|---|
void |
addPair(float[] startPt,
float[] stopPt,
byte[] startColor,
byte[] stopColor) |
static float |
AdotB(float[] A,
float[] B) |
static float[] |
AxB(float[] A,
float[] B) |
static float[] |
AxB(float[] A,
float[] B,
boolean unit) |
void |
checkTime(int timeIdx) |
void |
clean() |
void |
cleanDefStrp() |
static float[][] |
computeDisplacement(FlowInfo info,
float[][] spatial_values,
float[][] flow_values,
float timeStep) |
VisADGeometryArray[] |
computeTrajectories(int k,
double timeAccum,
double[] times,
double[] timeSteps) |
static float[][] |
convertFlowUnit(float[][] values,
Unit[] units) |
static double[] |
getBisectPlaneNormal(float[] uvecA,
float[] uvecB)
Determine the plane that bisects the angle at a vertex formed by intersecting lines
specified as two unit vectors (this plane is normal to the plane containing the vectors).
|
int |
getColorCount() |
int |
getCoordinateCount() |
static double[] |
getLinePlaneIntersect(double[] planeCoeffs,
double[] uVecLine,
double[] linePt)
Determine intersection point between a plane and a ray.
|
static double[] |
getLinePlaneIntersect(double a,
double b,
double c,
double d,
double[] uVecLine,
double[] linePt) |
int |
getNumberOfTrajectories() |
static int |
getNumIntrpPts(FlowInfo info,
float maxSpd,
double timeStep) |
static double[] |
getPlaneCoeffsFromNormalAndPoint(double[] normal,
double[] pt)
Determine a plane from the vector normal and point the plane should contain in form:
ax + by + cz + d = 0
|
static double[] |
getRotatedVecInPlane(double[] T,
double[] S,
double[] P,
double[] V,
double theta,
double[] rotV) |
static double[] |
getScale(MouseBehavior mouseBehav,
ProjectionControl pCntrl) |
void |
getStartPointsFromDomain(int trajForm,
int skip,
int zstart,
int zskip,
Gridded3DSet spatial_set,
byte[][] color_values,
float[][] startPts,
byte[][] startClrs,
float[][] flowValues,
float ribbonWidthFac) |
void |
getStartPointsFromDomain2D(int trajForm,
int skip,
float[][] setLocs,
int lenX,
int lenY,
byte[][] color_values,
float[][] startPts,
byte[][] startClrs,
float[][] flowValues,
float ribbonWidthFac) |
void |
getStartPointsFromDomain3D(int trajForm,
int skip,
int zstart,
int skipZ,
float[][] locs,
int lenX,
int lenY,
int lenZ,
byte[][] color_values,
float[][] startPts,
byte[][] startClrs,
float[][] flowValues,
float ribbonWidthFac) |
float[][] |
getStartPointsFromFile(DataRenderer renderer,
ScalarMap altToZ,
byte[][] colors) |
static double[] |
getTimes(Gridded1DSet timeSet) |
static double[] |
getTimeSteps(Gridded1DSet timeSet) |
static TrajectoryParams |
getTrajParamsFromFile(TrajectoryParams trajParams,
int which) |
void |
initCleanUp(ScalarMap scalarMap,
FlowControl flowCntrl,
ProjectionControl pCntrl,
DisplayImpl display) |
void |
makeCone(float[][] basePts,
float[] vertex,
byte[][] color,
float[] coords,
byte[] colors,
float[] normals,
int[] vertCnt) |
VisADGeometryArray[] |
makeCylinder() |
VisADGeometryArray |
makeDeformableRibbon() |
VisADGeometryArray |
makeFixedWidthRibbon() |
VisADGeometryArray |
makeGeometry() |
VisADGeometryArray |
makePointGeometry() |
static GriddedSet |
makeSpatialSetTraj(Gridded3DSet spatial_set) |
VisADGeometryArray |
makeTracerGeometry(ArrayList<float[]> anchors,
int direction,
float trcrSize,
double[] scale,
boolean fill) |
void |
makeTrajectories(double time,
float[][] startPts,
byte[][] color_values,
GriddedSet spatial_set) |
static float[][] |
mean(float[][] values0,
float[][] values1) |
static float[] |
mean(float[] values0,
float[] values1) |
void |
reset() |
static VisADGeometryArray |
scaleGeometry(VisADGeometryArray array,
ArrayList<float[]> anchors,
float scale) |
void |
setListener(ProjectionControl pCntrl,
ControlListener listener,
FlowControl flowCntrl) |
static float[][] |
smooth(float[][] values0,
float[][] values1,
float[][] values2,
TrajectoryParams.SmoothParams smoothParams) |
void |
updateInterpolators() |
static double |
vecMag(double[] vec) |
static float |
vecMag(float[] vec) |
public static boolean doStartOffset
public static int[] o_j
public static int[] o_i
public static final int LINE
public static final int RIBBON
public static final int CYLINDER
public static final int DEFORM_RIBBON
public static final int POINT
public static final String PPOP_TRAJECTORY_START_POINTS_FILE
public static final String PROP_TRAJECTORY_PARAM_FILE_1
public static final String PROP_TRAJECTORY_PARAM_FILE_2
public static final String PROP_TRAJECTORY_TERRAIN_FILE
public static HashMap<FlowControl,ControlListener> scaleChangeListeners
public static HashMap<ScalarMap,ScalarMapListener> removeListeners
public TrajectoryManager(DataRenderer renderer, TrajectoryParams trajParams, ArrayList<FlowInfo> flowInfoList, int dataDomainLength, double time) throws VisADException
VisADException
public TrajectoryManager(DataRenderer renderer, TrajectoryParams trajParams, ArrayList<FlowInfo> flowInfoList, int dataDomainLength, double time, ScalarMap altToZ, CoordinateSystem dspCoordSys) throws VisADException
VisADException
public void addPair(float[] startPt, float[] stopPt, byte[] startColor, byte[] stopColor)
public int getCoordinateCount()
public int getColorCount()
public int getNumberOfTrajectories()
public static int getNumIntrpPts(FlowInfo info, float maxSpd, double timeStep) throws VisADException
VisADException
public static float[][] computeDisplacement(FlowInfo info, float[][] spatial_values, float[][] flow_values, float timeStep) throws VisADException
VisADException
public VisADGeometryArray[] computeTrajectories(int k, double timeAccum, double[] times, double[] timeSteps) throws VisADException, RemoteException
k
- outer dimension (time) indextimeAccum
- accumulated time (see refresh interval)times
- time at each ktimeSteps
- step at each kVisADException
RemoteException
public void makeTrajectories(double time, float[][] startPts, byte[][] color_values, GriddedSet spatial_set) throws VisADException
VisADException
public void reset()
public void checkTime(int timeIdx)
public void clean()
public void cleanDefStrp()
public void updateInterpolators()
public static GriddedSet makeSpatialSetTraj(Gridded3DSet spatial_set) throws VisADException
VisADException
public static double[] getScale(MouseBehavior mouseBehav, ProjectionControl pCntrl)
public void getStartPointsFromDomain(int trajForm, int skip, int zstart, int zskip, Gridded3DSet spatial_set, byte[][] color_values, float[][] startPts, byte[][] startClrs, float[][] flowValues, float ribbonWidthFac) throws VisADException
VisADException
public void getStartPointsFromDomain3D(int trajForm, int skip, int zstart, int skipZ, float[][] locs, int lenX, int lenY, int lenZ, byte[][] color_values, float[][] startPts, byte[][] startClrs, float[][] flowValues, float ribbonWidthFac) throws VisADException
VisADException
public void getStartPointsFromDomain2D(int trajForm, int skip, float[][] setLocs, int lenX, int lenY, byte[][] color_values, float[][] startPts, byte[][] startClrs, float[][] flowValues, float ribbonWidthFac) throws VisADException
VisADException
public static float[][] convertFlowUnit(float[][] values, Unit[] units) throws VisADException
VisADException
public static float[][] smooth(float[][] values0, float[][] values1, float[][] values2, TrajectoryParams.SmoothParams smoothParams)
public static float[][] mean(float[][] values0, float[][] values1)
public static float[] mean(float[] values0, float[] values1)
public void setListener(ProjectionControl pCntrl, ControlListener listener, FlowControl flowCntrl)
public static double[] getTimeSteps(Gridded1DSet timeSet) throws VisADException
VisADException
public static double[] getTimes(Gridded1DSet timeSet) throws VisADException
VisADException
public static VisADGeometryArray scaleGeometry(VisADGeometryArray array, ArrayList<float[]> anchors, float scale)
public static float[] AxB(float[] A, float[] B)
public static float[] AxB(float[] A, float[] B, boolean unit)
public static float AdotB(float[] A, float[] B)
public static float vecMag(float[] vec)
public static double vecMag(double[] vec)
public static double[] getPlaneCoeffsFromNormalAndPoint(double[] normal, double[] pt)
normal
- vector normal to planept
- point on the planepublic static double[] getBisectPlaneNormal(float[] uvecA, float[] uvecB)
uvecA
- uvecB
- public static double[] getLinePlaneIntersect(double[] planeCoeffs, double[] uVecLine, double[] linePt)
planeCoeffs
- [a, b, c, d]: ax + by + cz + d = 0uVecLine
- unit vector specifying direction or raylinePt
- vertex of the ray.public static double[] getLinePlaneIntersect(double a, double b, double c, double d, double[] uVecLine, double[] linePt)
public static double[] getRotatedVecInPlane(double[] T, double[] S, double[] P, double[] V, double theta, double[] rotV)
T
- (SxT) right-handed in the plane. Must be 3D unit vectorsS
- P
- Origin, can be nullV
- The 2D (in S,T coordinates) vector to rotatetheta
- Counter-clockwise (> 0) rotation in the S,T planerotV
- The rotated vector, can be nullpublic VisADGeometryArray makeGeometry()
public VisADGeometryArray makeFixedWidthRibbon()
public VisADGeometryArray[] makeCylinder()
public void makeCone(float[][] basePts, float[] vertex, byte[][] color, float[] coords, byte[] colors, float[] normals, int[] vertCnt)
public VisADGeometryArray makeDeformableRibbon()
public VisADGeometryArray makePointGeometry()
public VisADGeometryArray makeTracerGeometry(ArrayList<float[]> anchors, int direction, float trcrSize, double[] scale, boolean fill)
public void initCleanUp(ScalarMap scalarMap, FlowControl flowCntrl, ProjectionControl pCntrl, DisplayImpl display)
public static TrajectoryParams getTrajParamsFromFile(TrajectoryParams trajParams, int which)
public float[][] getStartPointsFromFile(DataRenderer renderer, ScalarMap altToZ, byte[][] colors) throws VisADException, RemoteException
VisADException
RemoteException
Copyright © 1996–2023 The SSEC Visualization Project. All rights reserved.