testLineSegmentSphere
- bool testLineSegmentSphere(double p0X, double p0Y, double p0Z, double p1X, double p1Y, double p1Z, double centerX, double centerY, double centerZ, double radiusSquared)
- bool testLineSegmentSphere(Vector3d p0, Vector3d p1, Vector3d center, double radiusSquared)
public static
bool
testLineSegmentSphere
doml intersection_d
static functionsstatic variables
Test whether the line segment with the end points <code>p0</code> and <code>p1</code> intersects the given sphere with center <code>center</code> and square radius <code>radiusSquared</code>. <p> Reference: <a href="http://paulbourke.net/geometry/circlesphere/index.html#linesphere">http://paulbourke.net/</a>
@param p0 the line segment's first end point @param p1 the line segment's second end point @param center the sphere's center @param radiusSquared the sphere radius squared @return <code>true</code> if the line segment intersects the sphere; <code>false</code> otherwise