Create one plane
(optional) Input a unit length Vector3 defining the normal of the plane. Default is (1, 0, 0).
(optional) Input the signed distance from the origin to the plane. Default is 0.
Apply a Matrix4 to the plane. The matrix must be an affine, homogeneous transform. If supplying an optionalNormalMatrix, it can be created like so:
const optionalNormalMatrix = new THREE.Matrix3().getNormalMatrix( matrix );
Input the Matrix4 to apply.
(optional) Input pre-computed normal Matrix3 of the Matrix4 being applied.
Return this plane
Returns a 3d vector coplanar to the plane, by calculating the projection of the normal vector at the origin onto the plane.
Input the result will be copied into this 3d vector.
Return the 3d vector coplanar to the plane
Return the signed distance from the point to the plane.
Input one 3d point
Return the caculated distance
Project a point onto the plane.
Input a point to be projected
Input the result to be copied into.
Return the target
Set this plane's normal and constant properties by copying the values from the given normal.
Input a unit length 3d vector defining the normal of the plane.
Input the signed distance from the origin to the plane.
Return this plane
Set the individual components that define the plane.
Input x value of the unit length normal vector.
Input y value of the unit length normal vector.
Input z value of the unit length normal vector.
Input the value of the plane's constant property.
Return this plane
Defines the plane based on the 3 provided points. The winding order is assumed to be counter-clockwise, and determines the direction of the normal.
Input the first point on the plane.
Input the second point on the plane.
Input the third point on the plane.
Return this plane
Set the plane's properties as defined by a normal and an arbitrary coplanar point.
Input a unit length Vector3 defining the normal of the plane.
Input an arbitrary coplanar point.
Return this plane
Translates the plane by the distance defined by the offset vector. Note that this only affects the plane constant and will not affect the normal vector.
Input the amount to move the plane by.
Return this plane
A two dimensional surface that extends infinitely in 3d space, represented in Hessian normal form by a unit length normal vector and a constant.