6 #include "VectorMathDecl.h"
7 #include "PolylineInterpolationParams.h"
14 namespace LineSegments
16 double DistanceLineSegmentToPoint(
const dv3& lineSegmentStart,
const dv3& lineSegmentEnd,
const dv3& point,
double& out_param);
17 double DistanceSqrLineSegmentToPoint(
const dv3& lineSegmentStart,
const dv3& lineSegmentEnd,
const dv3& point,
double& out_param);
20 float DistanceLineSegmentToPoint(
const v3& lineSegmentStart,
const v3& lineSegmentEnd,
const v3& point,
float& out_param);
21 float DistanceSqrLineSegmentToPoint(
const v3& lineSegmentStart,
const v3& lineSegmentEnd,
const v3& point,
float& out_param);
22 float DistanceBetweenLineSegments(
const v3& startA,
const v3& endA,
const v3& startB,
const v3& endB,
float& out_paramA,
float& paramB);
23 float DistanceSqrBetweenLineSegments(
const v3& startA,
const v3& endA,
const v3& startB,
const v3& endB,
float& out_paramA,
float& paramB);
24 float ProjectPointOntoLineSegment(
const v3& lineSegmentStart,
const v3& lineSegmentEnd,
const v3& point);
26 bool IntersectsSphere(
const v3& lineSegmentStart,
const v3& lineSegmentEnd,
const v3& sphereCentre,
float sphereRadiusSq);
32 PolylineInterpolationParams GetPolylineInterpolationParams(
const std::vector<double>& polylineParams,
const double t);
34 std::vector<double> BuildPolylineParams(
const std::vector<dv3>& polylinePoints,
double& out_polylineLength);
36 std::vector<float> BuildPolylineParams(
const std::vector<v3>& polylinePoints,
float& out_polylineLength);