public readonly struct PlaneAn infinite plane, stored as the coefficients of dot(Normal, p) + D = 0. The side the normal points to is the front.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
D is the *negated* distance from the origin along the normal, which is the form that makes DotCoordinate a single dot product and is why every clipping and culling routine stores it this way.
Fields and properties (2)
public readonly Vector3 NormalThe plane's normal. Unit length for the distance methods to mean anything.
public readonly float DThe negated distance from the origin along Normal.
Methods (17)
public Plane(float a, float b, float c, float d)Builds a plane from its four coefficients.
public Plane(Vector3 normal, float d)Builds a plane from a normal and a distance.
public static Plane FromPointNormal(Vector3 point, Vector3 normal)The plane through facing .
public static Plane FromPoints(Vector3 a, Vector3 b, Vector3 c)The plane through three points, wound counter-clockwise when seen from the front.
public static Plane Normalize(Plane plane)Rescales the plane so its normal is unit length.
public float DotCoordinate(Vector3 point)The signed distance from to the plane: positive in front, negative behind, zero on it. Only a distance if the normal is unit length.
public float DotNormal(Vector3 direction)The dot product of the plane's normal with a direction, ignoring D.
public PlaneIntersectionType Classify(Vector3 point)Which side of the plane a point is on.
public static Plane Transform(Plane plane, in Matrix4x4 matrix)Moves a plane by a transform.
public static bool NearEqual(Plane left, Plane right, float tolerance = 1E-06)Whether two planes agree to within a tolerance.
public static bool operator ==(Plane left, Plane right)Exact equality, IEEE semantics. See NearEqual.
public static bool operator !=(Plane left, Plane right)The negation of op_Equality.
public bool Equals(Plane other)Indicates whether the current object is equal to another object of the same type.
public override bool Equals(object? obj)Indicates whether this instance and a specified object are equal.
public override int GetHashCode()Returns the hash code for this instance.
public override string ToString()Returns the fully qualified type name of this instance.
public string ToString(string? format, IFormatProvider? formatProvider)Formats the value of the current instance using the specified format.
Used by (21)
- BoundingBoxVixen.Core.Mathematics
- BoundingFrustumVixen.Core.Mathematics
- BoundingSphereVixen.Core.Mathematics
- FoliageCullViewRecordVixen.Rendering.Terrain
- GpuCullingVixen.Rendering
- MeshBooleanVixen.Geometry
- MeshBooleanPropertyTestsVixen.Geometry.Tests
- MeshBooleanTestsVixen.Geometry.Tests
- RayVixen.Core.Mathematics
- TypeRegistrationVixen.Core.Mathematics
- Vixen_Core_Mathematics_PlaneSerializerVixen.Core.Mathematics
- VolumeTestsVixen.Core.Mathematics.Tests
- BlockoutBooleanVixen.Editor.Blockout
- BlockoutBooleanTestsVixen.Editor.Blockout.Tests
- BlockoutCreateVixen.Editor.Blockout
- BlockoutCreateTestsVixen.Editor.Blockout.Tests
- BlockoutHistoryTestsVixen.Editor.Blockout.Tests
- BlockoutModeVixen.Editor.Blockout
- ScenePlacementVixen.Editor.SceneView
- TransformGizmoVixen.Editor.SceneView
- WorkPlaneVixen.Editor.SceneView