Box

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

Constructors

this
this(bound_t min_, bound_t max_)

Construct a box which extends between 2 points. 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_t
alias bound_t = Vector!(T, N)
Undocumented in source.

Functions

contains
bool contains(bound_t point)
contains
bool contains(Box other)
distance
double distance(bound_t point)

Euclidean distance from a point.

grow
Box grow(bound_t space)

Extends the area of this Box.

grow
Box grow(T space)

Extends the area of this Box.

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

Assign with another box.

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

Shrink the area of this Box.

shrink
Box shrink(T space)

Shrink the area of this Box.

squaredDistance
double squaredDistance(bound_t point)

Euclidean squared distance from a point.

Properties

center
bound_t center [@property getter]
depth
T depth [@property getter]
height
T height [@property getter]
size
bound_t size [@property getter]
volume
T volume [@property getter]
width
T width [@property getter]

Variables

max
bound_t max;
Undocumented in source.
min
bound_t min;
Undocumented in source.

Meta