16 template <
typename Real>
31 template <
typename Real>
40 auto lbResult = lbQuery(line, box);
42 if (lbResult.lineParameter >= (Real)0)
44 result.sqrDistance = lbResult.sqrDistance;
45 result.distance = lbResult.distance;
46 result.rayParameter = lbResult.lineParameter;
47 result.closestPoint[0] = lbResult.closestPoint[0];
48 result.closestPoint[1] = lbResult.closestPoint[1];
53 auto pbResult = pbQuery(ray.origin, box);
54 result.sqrDistance = pbResult.sqrDistance;
55 result.distance = pbResult.distance;
56 result.rayParameter = (Real)0;
57 result.closestPoint[0] = ray.origin;
58 result.closestPoint[1] = pbResult.boxClosest;
GLsizei GLsizei GLfloat distance
Result operator()(Type0 const &primitive0, Type1 const &primitive1)