#include <boundingbox.h>
Inheritance diagram for Boundary::AARBoundingBox< T, Boolean, Float, BoxType >:
Basically just a wrapper around the given BoxType using the virtual function interface of BoundingBox<>, which allows this class to be compatible with other bounding box classes.
Definition at line 81 of file boundingbox.h.
Public Methods | |
AARBoundingBox () | |
Default constructor: infinite extent. | |
AARBoundingBox (T xlow, T ylow, T xhigh, T yhigh) | |
Typical constructor: square box. | |
AARBoundingBox (T centerx, T centery, T radius) | |
Constructor taking a center and a radius for a square box with odd dimensions. | |
virtual Boolean | inside (T x, T y) const |
Whether the given point is enclosed by the box, inclusively. | |
virtual self & | set () |
Make the bounding box infinite. | |
virtual self & | set (T xlow, T ylow, T xhigh, T yhigh) |
Set the bounding box to the given dimensions. | |
virtual self & | operator+= (const self &b) |
Expand this box to enclose the given one. | |
virtual base & | scale (T xscale, T yscale) |
Scale the size of the box in X and Y dimensions. | |
virtual base & | rotate (Float theta) |
Rotate the box by the given angle (in radians) and take the smallest axis-aligned rectangle which encloses the result. | |
virtual base & | translate (T xoffset, T yoffset) |
Translate the origin of the box elsewhere. | |
virtual base::Rectangle | aarectangle () const |
Returns an axis-aligned rectangle fully enclosing this box, or an empty rectangle if no such finite rectangle exists. | |
virtual base * | clone () const |
Constructs an identical copy of self and returns it. | |
virtual std::ostream & | put (std::ostream &s) const |
Virtual interface to the operator<<, since << cannot be virtual. | |
virtual Boolean | empty () const |
Enclosing a single point or line is considered empty since zero area is enclosed. | |
Protected Attributes | |
BoxType | box |
|
Virtual interface to the operator<<, since << cannot be virtual. This implementation is just a stub, and should be overriden in derived classes. Outputs a human-readable representation to the given stream. Reimplemented from Boundary::BoundingBox< T, Boolean, Float >. Definition at line 127 of file boundingbox.h. |