Box

N-dimensional half-open interval [a, b[.

Constructors

this
this(Bound min_, Bound max_)

Construct a box which extends between 2 points. Boundaries: min is inside the box, max is just outside.

this
this(T min_, T max_)
Undocumented in source.
this
this(T min_x, T min_y, T max_x, T max_y)
Undocumented in source.
this
this(T min_x, T min_y, T min_z, T max_x, T max_y, T max_z)
Undocumented in source.

Members

Aliases

Bound
alias Bound = Vector!(T, N)
Undocumented in source.

Functions

area
T area()
center
Bound center()
contains
bool contains(Bound point)
contains
bool contains(Box other)
depth
T depth()
distance
double distance(Vector!(U, N) point)

Euclidean distance from a point.

grow
Box grow(Bound space)

Extends the area of this Box.

grow
Box grow(T space)

Extends the area of this Box.

height
T height()
intersect
Box intersect(const(Box) o)
Undocumented in source. Be warned that the author may not have intended to support it.
opAssign
Box opAssign(U x)

Assign with another box.

opCmp
int opCmp(Box rhs)

Comparison with another Box (for sorting).

opEquals
bool opEquals(U other)
shrink
Box shrink(Bound space)

Shrink the area of this Box.

shrink
Box shrink(T space)

Shrink the area of this Box.

size
Bound size()
squaredDistance
double squaredDistance(Vector!(U, N) point)

Euclidean squared distance from a point.

volume
T volume()
width
T width()

Variables

max
Bound max;
Undocumented in source.
min
Bound min;
Undocumented in source.

Meta