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.

Members

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()
opAssign
Box opAssign(U x)

Assign with another box.

opCmp
int opCmp(ref const 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()

Meta