18 template <
typename Real>
34 template <
typename Real>
43 segment.GetCenteredForm(segCenter, segDirection, segExtent);
47 auto lbResult = lbQuery(line, box);
49 if (lbResult.lineParameter >= -segExtent)
51 if (lbResult.lineParameter <= segExtent)
53 result.sqrDistance = lbResult.sqrDistance;
54 result.distance = lbResult.distance;
55 result.segmentParameter = lbResult.lineParameter;
56 result.closestPoint[0] = lbResult.closestPoint[0];
57 result.closestPoint[1] = lbResult.closestPoint[1];
63 auto pbResult = pbQuery(point, box);
64 result.sqrDistance = pbResult.sqrDistance;
65 result.distance = pbResult.distance;
66 result.segmentParameter = segExtent;
67 result.closestPoint[0] = point;
68 result.closestPoint[1] = pbResult.boxClosest;
75 auto pbResult = pbQuery(point, box);
76 result.sqrDistance = pbResult.sqrDistance;
77 result.distance = pbResult.distance;
78 result.segmentParameter = segExtent;
79 result.closestPoint[0] = point;
80 result.closestPoint[1] = pbResult.boxClosest;
GLsizei GLsizei GLfloat distance
Result operator()(Type0 const &primitive0, Type1 const &primitive1)