Plane Struct

Representation of planes.

A plane is defined by a normal vector and distance from the origin to the plane.

Variables
normal

Normal vector of the plane.

distance

Distance from the origin to the plane.

Constructors
Plane

Creates a plane.

Functions
SetNormalAndPosition

Sets a plane using a point that lies within it plus a normal to orient it (note that the normal must be a normalised vector).

Set3Points

Sets a plane using three points that lie within it. The points go around clockwise as you look down on the top surface of the plane.

GetDistanceToPoint

Returns a signed distance from plane to point.

GetSide

Is a point on the positive side of the plane?

SameSide

Are two points on the same side of the plane?

Raycast

Intersects a ray with the plane.