PlaneT

Base template for all plane-types.

Constructors

this
this(pt a, pt b, pt c, pt d)
this(vec3 normal, pt d)

Constructs the plane, from either four scalars of type pt or from a 3-dimensional vector (= normal) and a scalar.

Members

Aliases

pt
alias pt = type
Undocumented in source.
vec3
alias vec3 = Vector!(pt, 3)
Undocumented in source.

Functions

distance
pt distance(vec3 point)

Returns the distance from a point to the plane. Note: the plane must be normalized, the result can be negative.

ndistance
pt ndistance(vec3 point)

Returns the distance from a point to the plane. Note: the plane does not have to be normalized, the result can be negative.

normalize
void normalize()

Normalizes the plane inplace.

opEquals
bool opEquals(PlaneT other)
Undocumented in source. Be warned that the author may not have intended to support it.
toHash
size_t toHash()

Gets a hash of this item

Properties

normalized
PlaneT normalized [@property getter]

Returns a normalized copy of the plane.

Unions

__anonymous
union __anonymous
Undocumented in source.

Variables

d
pt d;

Holds the planes "constant" (HNF).

Parameters

type

all values get stored as this type (must be floating point)

Meta