Class BoundingSphereExtensions
- Namespace
- HelixToolkit.Maths
- Assembly
- HelixToolkit.Maths.dll
public static class BoundingSphereExtensions
- Inheritance
-
BoundingSphereExtensions
- Inherited Members
Methods
DistanceTo(BoundingSphere, Vector3)
Calculates the distance from a point to the nearest point on the sphere surface.
public static float DistanceTo(this BoundingSphere b, Vector3 point)
Parameters
bBoundingSphereThe BoundingSphere
pointVector3The point
Returns
- float
The distance
GetBoundingSphere(IList<Vector3>)
Froms the points.
public static BoundingSphere GetBoundingSphere(this IList<Vector3> points)
Parameters
Returns
GetBoundingSphere(IList<Vector3>, int, int)
Get bounding sphere from point list.
public static BoundingSphere GetBoundingSphere(this IList<Vector3> points, int start, int count)
Parameters
Returns
Intersects(BoundingSphere, Ray, out Vector3[]?)
Gets the intersection with the specified ray.
public static bool Intersects(this BoundingSphere box, Ray ray, out Vector3[]? points)
Parameters
boxBoundingSphereThe BoundingSphere
rayRayThe ray.
pointsVector3[]The intersection point(s).
Returns
- bool
The intersection points sorted by distance from the ray origin.
TransformBoundingSphere(BoundingSphere, Matrix4x4)
Transforms the bounding sphere.
public static BoundingSphere TransformBoundingSphere(this BoundingSphere b, Matrix4x4 m)
Parameters
bBoundingSphereThe b.
mMatrix4x4The m.