Gravity Engine 12.0
Unity Asset for Gravity
|
Trajectory data. Class to hold points in a trajectory in "sorted" order. Each point contains a position, velocity and time. More...
Classes | |
class | Intercept |
Container class to hold the points on two trajectories at an intercept point. More... | |
class | InterceptComparer |
class | Tpoint |
class | TpointCompare |
Public Member Functions | |
IEnumerator | GetEnumerator () |
void | AddPoint (Vector3 r, Vector3 v, float t) |
int | TrimEarlier (double cutoffTime, double buffer) |
int | Count () |
void | MoveAll (Vector3 moveBy) |
List< Tpoint > | AsSortedList () |
List< Intercept > | GetIntercepts (TrajectoryData tdata, float deltaDistance, float deltaTime) |
Compare this trajectory data set to another and find those points that are within the specified deltaDistance. DeltaDistance denotes the seperation in EACH co-ordinate (i.e. they are within in a BOX of size delta distance) to reduce CPU cost of calculating exact distance.) | |
Trajectory data. Class to hold points in a trajectory in "sorted" order. Each point contains a position, velocity and time.
Insertion maintains order. This facilitates determining if two trajectory paths get close enough to be considered as "crossing".
List< Intercept > TrajectoryData.GetIntercepts | ( | TrajectoryData | tdata, |
float | deltaDistance, | ||
float | deltaTime | ||
) |
Compare this trajectory data set to another and find those points that are within the specified deltaDistance. DeltaDistance denotes the seperation in EACH co-ordinate (i.e. they are within in a BOX of size delta distance) to reduce CPU cost of calculating exact distance.)
DeltaTime specifies the time within which multiple intercept points should be regarded as duplicates (in which case the intercept with the closest approach is used)
List of intercepts is provided in time order (earliest first)
tdata | |
deltaDistance | |
deltaTime |