@JsType(isNative=true, namespace="Cesium", name="IntersectionTests") public class IntersectionTests extends Object
Modifier and Type | Method and Description |
---|---|
static Cartesian3 |
grazingAltitudeLocation(Ray ray,
Ellipsoid ellipsoid)
Provides the point along the ray which is nearest to the ellipsoid.
|
static Cartesian3 |
lineSegmentPlane(Cartesian3 endPoint0,
Cartesian3 endPoint1,
Plane plane)
Computes the intersection of a line segment and a plane.
|
static Cartesian3 |
lineSegmentPlane(Cartesian3 endPoint0,
Cartesian3 endPoint1,
Plane plane,
Cartesian3 result)
Computes the intersection of a line segment and a plane.
|
static Interval |
lineSegmentSphere(Cartesian3 p0,
Cartesian3 p1,
BoundingSphere sphere)
Computes the intersection points of a line segment with a sphere.
|
static Interval |
lineSegmentSphere(Cartesian3 p0,
Cartesian3 p1,
BoundingSphere sphere,
Interval result)
Computes the intersection points of a line segment with a sphere.
|
static Cartesian3 |
lineSegmentTriangle(Cartesian3 v0,
Cartesian3 v1,
Cartesian3 p0,
Cartesian3 p1,
Cartesian3 p2)
Computes the intersection of a line segment and a triangle.
|
static Cartesian3 |
lineSegmentTriangle(Cartesian3 v0,
Cartesian3 v1,
Cartesian3 p0,
Cartesian3 p1,
Cartesian3 p2,
boolean cullBackFaces)
Computes the intersection of a line segment and a triangle.
|
static Cartesian3 |
lineSegmentTriangle(Cartesian3 v0,
Cartesian3 v1,
Cartesian3 p0,
Cartesian3 p1,
Cartesian3 p2,
boolean cullBackFaces,
Cartesian3 result)
Computes the intersection of a line segment and a triangle.
|
static Interval |
rayEllipsoid(Ray ray,
Ellipsoid ellipsoid)
Computes the intersection points of a ray with an ellipsoid.
|
static Cartesian3 |
rayPlane(Ray ray,
Plane plane)
Computes the intersection of a ray and a plane.
|
static Cartesian3 |
rayPlane(Ray ray,
Plane plane,
Cartesian3 result)
Computes the intersection of a ray and a plane.
|
static Interval |
raySphere(Ray ray,
BoundingSphere sphere)
Computes the intersection points of a ray with a sphere.
|
static Interval |
raySphere(Ray ray,
BoundingSphere sphere,
Interval result)
Computes the intersection points of a ray with a sphere.
|
static Cartesian3 |
rayTriangle(Ray ray,
Cartesian3 p0,
Cartesian3 p1,
Cartesian3 p2)
Computes the intersection of a ray and a triangle as a Cartesian3 coordinate.
|
static Cartesian3 |
rayTriangle(Ray ray,
Cartesian3 p0,
Cartesian3 p1,
Cartesian3 p2,
boolean cullBackFaces)
Computes the intersection of a ray and a triangle as a Cartesian3 coordinate.
|
static Cartesian3 |
rayTriangle(Ray ray,
Cartesian3 p0,
Cartesian3 p1,
Cartesian3 p2,
boolean cullBackFaces,
Cartesian3 result)
Computes the intersection of a ray and a triangle as a Cartesian3 coordinate.
|
static double |
rayTriangleParametric(Cartesian3 ray,
Cartesian3 p0,
Cartesian3 p1,
Cartesian3 p2)
Computes the intersection of a ray and a triangle as a parametric distance along the input ray.
|
static double |
rayTriangleParametric(Cartesian3 ray,
Cartesian3 p0,
Cartesian3 p1,
Cartesian3 p2,
boolean cullBackFaces)
Computes the intersection of a ray and a triangle as a parametric distance along the input ray.
|
static Object |
trianglePlaneIntersection(Cartesian3 p0,
Cartesian3 p1,
Cartesian3 p2,
Plane plane)
Computes the intersection of a triangle and a plane
|
@JsMethod public static Interval lineSegmentSphere(Cartesian3 p0, Cartesian3 p1, BoundingSphere sphere)
p0
- An end point of the line segment.p1
- The other end point of the line segment.sphere
- The sphere.@JsMethod public static Interval lineSegmentSphere(Cartesian3 p0, Cartesian3 p1, BoundingSphere sphere, Interval result)
p0
- An end point of the line segment.p1
- The other end point of the line segment.sphere
- The sphere.result
- The result onto which to store the result.@JsMethod public static Cartesian3 lineSegmentTriangle(Cartesian3 v0, Cartesian3 v1, Cartesian3 p0, Cartesian3 p1, Cartesian3 p2)
v0
- The an end point of the line segment.v1
- The other end point of the line segment.p0
- The first vertex of the triangle.p1
- The second vertex of the triangle.p2
- The third vertex of the triangle.@JsMethod public static Cartesian3 lineSegmentTriangle(Cartesian3 v0, Cartesian3 v1, Cartesian3 p0, Cartesian3 p1, Cartesian3 p2, boolean cullBackFaces)
v0
- The an end point of the line segment.v1
- The other end point of the line segment.p0
- The first vertex of the triangle.p1
- The second vertex of the triangle.p2
- The third vertex of the triangle.cullBackFaces
- If true, will only compute an intersection with the front face of the triangle and return
undefined for intersections with the back face.@JsMethod public static Cartesian3 lineSegmentTriangle(Cartesian3 v0, Cartesian3 v1, Cartesian3 p0, Cartesian3 p1, Cartesian3 p2, boolean cullBackFaces, Cartesian3 result)
v0
- The an end point of the line segment.v1
- The other end point of the line segment.p0
- The first vertex of the triangle.p1
- The second vertex of the triangle.p2
- The third vertex of the triangle.cullBackFaces
- If true, will only compute an intersection with the front face of the triangle and return
undefined for intersections with the back face.result
- The Cartesian3 onto which to store the result.@JsMethod public static Interval raySphere(Ray ray, BoundingSphere sphere)
ray
- The ray.sphere
- The sphere.@JsMethod public static Interval raySphere(Ray ray, BoundingSphere sphere, Interval result)
ray
- The ray.sphere
- The sphere.result
- The result onto which to store the result.@JsMethod public static Cartesian3 rayTriangle(Ray ray, Cartesian3 p0, Cartesian3 p1, Cartesian3 p2)
ray
- The ray.p0
- The first vertex of the triangle.p1
- The second vertex of the triangle.p2
- The third vertex of the triangle.@JsMethod public static Cartesian3 rayTriangle(Ray ray, Cartesian3 p0, Cartesian3 p1, Cartesian3 p2, boolean cullBackFaces)
ray
- The ray.p0
- The first vertex of the triangle.p1
- The second vertex of the triangle.p2
- The third vertex of the triangle.cullBackFaces
- If true, will only compute an intersection with the front face of the triangle and return undefined for intersections with the back face.@JsMethod public static Cartesian3 rayTriangle(Ray ray, Cartesian3 p0, Cartesian3 p1, Cartesian3 p2, boolean cullBackFaces, Cartesian3 result)
ray
- The ray.p0
- The first vertex of the triangle.p1
- The second vertex of the triangle.p2
- The third vertex of the triangle.cullBackFaces
- If true, will only compute an intersection with the front face of the triangle and return undefined for intersections with the back face.result
- The Cartesian3 onto which to store the result.@JsMethod public static double rayTriangleParametric(Cartesian3 ray, Cartesian3 p0, Cartesian3 p1, Cartesian3 p2)
ray
- The ray.p0
- The first vertex of the triangle.p1
- The second vertex of the triangle.p2
- The third vertex of the triangle.@JsMethod public static double rayTriangleParametric(Cartesian3 ray, Cartesian3 p0, Cartesian3 p1, Cartesian3 p2, boolean cullBackFaces)
ray
- The ray.p0
- The first vertex of the triangle.p1
- The second vertex of the triangle.p2
- The third vertex of the triangle.cullBackFaces
- If true, will only compute an intersection with the front face of the triangle and return undefined for intersections with the back face.@JsMethod public static Cartesian3 grazingAltitudeLocation(Ray ray, Ellipsoid ellipsoid)
ray
- The ray.ellipsoid
- The ellipsoid.@JsMethod public static Cartesian3 lineSegmentPlane(Cartesian3 endPoint0, Cartesian3 endPoint1, Plane plane)
endPoint0
- An end point of the line segment.endPoint1
- The other end point of the line segment.plane
- The plane.@JsMethod public static Cartesian3 lineSegmentPlane(Cartesian3 endPoint0, Cartesian3 endPoint1, Plane plane, Cartesian3 result)
endPoint0
- An end point of the line segment.endPoint1
- The other end point of the line segment.plane
- The plane.result
- The object onto which to store the result.@JsMethod public static Interval rayEllipsoid(Ray ray, Ellipsoid ellipsoid)
ray
- The ray.ellipsoid
- The ellipsoid.@JsMethod public static Cartesian3 rayPlane(Ray ray, Plane plane)
ray
- The ray.plane
- The plane.@JsMethod public static Cartesian3 rayPlane(Ray ray, Plane plane, Cartesian3 result)
ray
- The ray.plane
- The plane.result
- The object onto which to store the result.@JsMethod public static Object trianglePlaneIntersection(Cartesian3 p0, Cartesian3 p1, Cartesian3 p2, Plane plane)
p0
- First point of the trianglep1
- Second point of the trianglep2
- Third point of the triangleplane
- Intersection planeCopyright © 2019. All rights reserved.