17 template <
typename Real>
20 public DCPQuery<Real, Line3<Real>, AlignedBox3<Real>>
25 public DCPQuery<Real, Line3<Real>, AlignedBox3<Real>>::Result
34 template <
typename Real>
43 for (
int i = 0; i < 3; ++i)
45 point[i] =
Dot(diff, box.axis[i]);
46 direction[i] =
Dot(line.direction, box.axis[i]);
50 this->DoQuery(point, direction, box.extent, result);
53 result.closestPoint[0] =
54 line.origin + result.lineParameter*line.direction;
57 result.closestPoint[1] = box.center;
58 for (
int i = 0; i < 3; ++i)
60 result.closestPoint[1] += point[i] * box.axis[i];
Result operator()(Type0 const &primitive0, Type1 const &primitive1)
DualQuaternion< Real > Dot(DualQuaternion< Real > const &d0, DualQuaternion< Real > const &d1)