#include <CGAL/Bbox_d.h>
template<typename DimensionTag>
class CGAL::Bbox_d< DimensionTag >
An object b
of the class Bbox_d
is a bounding box in the d-dimensional Euclidean space \( \E^d\).
- Template Parameters
-
- Is model of
Hashable
- See also
CGAL::Bbox_2
-
CGAL::Bbox_3
|
An iterator for enumerating the Cartesian coordinates of the point with the lexicographically
|
typedef unspecified_type | Cartesian_const_iterator |
|
|
| Bbox_d () |
| constructs an empty bounding box with lower left corner coordinates at \( \infty \) and with upper right corner coordinates at \( -\infty \), \( \infty \) being std::numeric_limits<double>::infinity() .
|
|
| Bbox_d (const Bbox_2 &b) |
| constructs a d-dimensional bounding box from a 2D bounding box.
|
|
template<typename InputIterator > |
| Bbox_d (int d, InputIterator b, InputIterator e) |
| constructs a d-dimensional bounding box from a range of coordinates
|
|
| Bbox_d (const Bbox_3 &b) |
| constructs a d-dimensional bounding box from a 3D bounding box.
|
|
|
bool | operator== (const Bbox_d &c) const |
| tests for equality.
|
|
bool | operator!= (const Bbox_d &q) const |
| tests for inequality.
|
|
int | dimension () const |
| returns the dimension.
|
|
double | min (int i) const |
| returns the i -th Cartesian coordinate of the "lower left" corner.
|
|
double | max (int i) const |
| returns the i -th Cartesian coordinate of the "upper right" corner.
|
|
Cartesian_const_iterator | cartesian_begin () const |
| returns an iterator for the Cartesian coordinates of the "lower left" and the "upper right" corner.
|
|
Cartesian_const_iterator | cartesian_end () const |
| returns the past-the-end iterator for the Cartesian coordinates of the "lower left" and the "upper right" corner.
|
|
Bbox_d | operator+ (const Bbox_d &c) const |
| returns a bounding box of b and c .
|
|
Bbox_d & | operator+= (const Bbox_d &c) |
| updates b to be the bounding box of b and c and returns itself.
|
|
void | dilate (int dist) |
| dilates the bounding box by a specified number of ULP.
|
|
void | scale (double factor) |
| scales the bounding box by factor , while keeping its center fixed.
|
|
template<typename DimensionTag > |
bool | do_overlap (const Bbox_d< DimensionTag > &bb1, const Bbox_d< DimensionTag > &bb2) |
| returns true , iff bb1 and bb2 overlap, i.e., iff their intersection is non-empty.
|
|
◆ Bbox_d() [1/3]
template<typename DimensionTag >
constructs a d-dimensional bounding box from a 2D bounding box.
- Precondition
- the dimension must be 2D
◆ Bbox_d() [2/3]
template<typename DimensionTag >
constructs a d-dimensional bounding box from a range of coordinates
- Precondition
- the range must have the size of the dimension.
- Template Parameters
-
◆ Bbox_d() [3/3]
template<typename DimensionTag >
constructs a d-dimensional bounding box from a 3D bounding box.
- Precondition
- the dimension must be 3D
◆ scale()
template<typename DimensionTag >
scales the bounding box by factor
, while keeping its center fixed.
- Precondition
factor > 0