new Plane
A plane in Hessian Normal Form defined by
ax + by + cz + d = 0where (a, b, c) is the plane's
normal
, d is the signed
distance
to the plane, and (x, y, z) is any point on
the plane.
Parameters:
Name | Type | Description |
---|---|---|
normal |
Cartesian3 | The plane's normal (normalized). |
distance |
Number | The shortest distance from the origin to the plane. The sign of
distance determines which side of the plane the origin
is on. If distance is positive, the origin is in the half-space
in the direction of the normal; if negative, the origin is in the half-space
opposite to the normal; if zero, the plane passes through the origin. |
Throws:
-
DeveloperError : normal is required.
-
DeveloperError : distance is required.
Example
// The plane x=0 var plane = new Plane(Cartesian3.UNIT_X, 0.0);
Source:
Members
-
distance :Number
-
The shortest distance from the origin to the plane. The sign of
distance
determines which side of the plane the origin is on. Ifdistance
is positive, the origin is in the half-space in the direction of the normal; if negative, the origin is in the half-space opposite to the normal; if zero, the plane passes through the origin. -
normal :Cartesian3
-
The plane's normal.
Methods
-
getPointDistance
-
Computes the signed shortest distance of a point to this plane. The sign of the distance determines which side of this plane the point is on. If the distance is positive, the point is in the half-space in the direction of the normal; if negative, the point is in the half-space opposite to the normal; if zero, this plane passes through the point.
Parameters:
Name Type Description point
Cartesian3 The point. Throws:
DeveloperError : point is required.Returns:
Number The signed shortest distance of the point to this plane. -
<static> fromPointNormal
-
Creates a plane from a normal and a point on the plane.
Parameters:
Name Type Argument Description point
Cartesian3 The point on the plane. normal
Cartesian3 The plane's normal (normalized). result
Plane <optional>
The object onto which to store the result. Throws:
-
DeveloperError : point is required.
-
DeveloperError : normal is required.
Returns:
Plane A new plane instance or the modified result parameter.Example
var point = ellipsoid.cartographicToCartesian(Cartographic.fromDegrees(-72.0, 40.0)); var normal = ellipsoid.geodeticSurfaceNormal(point); var tangentPlane = Plane.fromPointNormal(point, normal);
-
-
<static> getPointDistance
-
Computes the signed shortest distance of a point to a plane. The sign of the distance determines which side of the plane the point is on. If the distance is positive, the point is in the half-space in the direction of the normal; if negative, the point is in the half-space opposite to the normal; if zero, the plane passes through the point.
Parameters:
Name Type Description plane
Plane The plane. point
Cartesian3 The point. Throws:
-
DeveloperError : plane is required.
-
DeveloperError : point is required.
Returns:
Number The signed shortest distance of the point to the plane. -