IntersectionTests

external object IntersectionTests(source)

Functions for computing the intersection between geometries such as rays, planes, triangles, and ellipsoids.

See also

Functions

Link copied to clipboard
external fun grazingAltitudeLocation(ray: Ray, ellipsoid: Ellipsoid): Cartesian3

Provides the point along the ray which is nearest to the ellipsoid.

Link copied to clipboard
external fun lineSegmentPlane(endPoint0: Cartesian3, endPoint1: Cartesian3, plane: Plane, result: Cartesian3? = definedExternally): Cartesian3

Computes the intersection of a line segment and a plane.

Link copied to clipboard
external fun lineSegmentSphere(p0: Cartesian3, p1: Cartesian3, sphere: BoundingSphere, result: Interval? = definedExternally): Interval

Computes the intersection points of a line segment with a sphere.

Link copied to clipboard
external fun lineSegmentTriangle(v0: Cartesian3, v1: Cartesian3, p0: Cartesian3, p1: Cartesian3, p2: Cartesian3, cullBackFaces: Boolean? = definedExternally, result: Cartesian3? = definedExternally): Cartesian3

Computes the intersection of a line segment and a triangle.

Link copied to clipboard

Computes the intersection points of a ray with an axis-aligned bounding box. (axis-aligned in the same space as the ray)

Link copied to clipboard
external fun rayEllipsoid(ray: Ray, ellipsoid: Ellipsoid): Interval

Computes the intersection points of a ray with an ellipsoid.

Link copied to clipboard
external fun rayPlane(ray: Ray, plane: Plane, result: Cartesian3? = definedExternally): Cartesian3

Computes the intersection of a ray and a plane.

Link copied to clipboard
external fun raySphere(ray: Ray, sphere: BoundingSphere, result: Interval? = definedExternally): Interval

Computes the intersection points of a ray with a sphere.

Link copied to clipboard
external fun rayTriangle(ray: Ray, p0: Cartesian3, p1: Cartesian3, p2: Cartesian3, cullBackFaces: Boolean? = definedExternally, result: Cartesian3? = definedExternally): Cartesian3

Computes the intersection of a ray and a triangle as a Cartesian3 coordinate.

Link copied to clipboard
external fun rayTriangleParametric(ray: Ray, p0: Cartesian3, p1: Cartesian3, p2: Cartesian3, cullBackFaces: Boolean? = definedExternally): Double

Computes the intersection of a ray and a triangle as a parametric distance along the input ray. The result is negative when the triangle is behind the ray.

Link copied to clipboard

Computes the intersection of a triangle and a plane