Rocstar  1.0
Rocstar multiphysics simulation application
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Bbox_2 Class Reference

#include <Bbox_2.h>

Inheritance diagram for Bbox_2:
Collaboration diagram for Bbox_2:

Public Member Functions

 Bbox_2 ()
 
 Bbox_2 (double x_min, double y_min, double x_max, double y_max)
 
bool operator== (const Bbox_2 &b) const
 
bool operator!= (const Bbox_2 &b) const
 
int dimension () const
 
double xmin () const
 
double ymin () const
 
double xmax () const
 
double ymax () const
 
double max (int i) const
 
double min (int i) const
 
Bbox_2 operator+ (const Bbox_2 &b) const
 
 Bbox_2 ()
 
 Bbox_2 (double x_min, double y_min, double x_max, double y_max)
 
int dimension () const
 
double xmin () const
 
double ymin () const
 
double xmax () const
 
double ymax () const
 
double min (int i) const
 
double max (int i) const
 
Bbox_2 operator+ (const Bbox_2 &b) const
 
Bbox_2operator+= (const Bbox_2 &b)
 

Private Attributes

double _min [2]
 
double _max [2]
 

Detailed Description

Definition at line 65 of file CGAL/include/CGAL/Bbox_2.h.

Constructor & Destructor Documentation

Definition at line 56 of file Bbox_2.C.

Referenced by operator+().

57 { new ( static_cast< void*>(ptr)) Fourtuple<double>(); }

Here is the caller graph for this function:

Bbox_2 ( double  x_min,
double  y_min,
double  x_max,
double  y_max 
)

Definition at line 59 of file Bbox_2.C.

61 {
62  new ( static_cast< void*>(ptr)) Fourtuple<double>(x_min, y_min,
63  x_max, y_max);
64 }
Bbox_2 ( )
inline

Definition at line 36 of file include/CGAL/Bbox_2.h.

References _max, and _min.

36  {
37  _min[0] = _min[1] = HUGE_VAL;
38  _max[0] = _max[1] = -HUGE_VAL;
39  }
double _max[2]
double _min[2]
Bbox_2 ( double  x_min,
double  y_min,
double  x_max,
double  y_max 
)
inline

Definition at line 40 of file include/CGAL/Bbox_2.h.

References _max, and _min.

41  { _min[0]=x_min; _min[1]=y_min; _max[0]=x_max; _max[1]=y_max; }
double _max[2]
double _min[2]

Member Function Documentation

int dimension ( ) const
inline

Definition at line 48 of file include/CGAL/Bbox_2.h.

48 { return 2; }
int dimension ( ) const
inline

Definition at line 91 of file CGAL/include/CGAL/Bbox_2.h.

92 { return 2; }
double max ( int  i) const
inline

Definition at line 63 of file include/CGAL/Bbox_2.h.

References CGAL_kernel_precondition, xmax(), and ymax().

63  {
64  CGAL_kernel_precondition( (i == 0 ) || ( i == 1 ) );
65  if(i == 0) {
66  return xmax();
67  }
68  return ymax();
69  }
double xmax() const
blockLoc i
Definition: read.cpp:79
double ymax() const
#define CGAL_kernel_precondition(EX)

Here is the call graph for this function:

double max ( int  i) const
inline

Definition at line 125 of file CGAL/include/CGAL/Bbox_2.h.

References CGAL_kernel_precondition, xmax(), and ymax().

126 {
127  CGAL_kernel_precondition( (i == 0 ) || ( i == 1 ) );
128  if(i == 0) { return xmax(); }
129  return ymax();
130 }
double xmax() const
blockLoc i
Definition: read.cpp:79
double ymax() const
#define CGAL_kernel_precondition(EX)

Here is the call graph for this function:

double min ( int  i) const
inline

Definition at line 55 of file include/CGAL/Bbox_2.h.

References CGAL_kernel_precondition, xmin(), and ymin().

55  {
56  CGAL_kernel_precondition( (i == 0 ) || ( i == 1 ) );
57  if(i == 0) {
58  return xmin();
59  }
60  return ymin();
61  }
double ymin() const
double xmin() const
blockLoc i
Definition: read.cpp:79
#define CGAL_kernel_precondition(EX)

Here is the call graph for this function:

double min ( int  i) const
inline

Definition at line 116 of file CGAL/include/CGAL/Bbox_2.h.

References CGAL_kernel_precondition, xmin(), and ymin().

117 {
118  CGAL_kernel_precondition( (i == 0 ) || ( i == 1 ) );
119  if(i == 0) { return xmin(); }
120  return ymin();
121 }
double ymin() const
double xmin() const
blockLoc i
Definition: read.cpp:79
#define CGAL_kernel_precondition(EX)

Here is the call graph for this function:

bool operator!= ( const Bbox_2 b) const

Definition at line 72 of file Bbox_2.C.

73 {
74  return ! (b == *this);
75 }
Bbox_2 operator+ ( const Bbox_2 b) const
inline

Definition at line 71 of file include/CGAL/Bbox_2.h.

71  {
72  Bbox_2 box=*this; box+=b; return box;
73  }
KD_tree::Box box
Definition: Overlay_0d.C:47
Bbox_2 operator+ ( const Bbox_2 b) const
inline

Definition at line 131 of file CGAL/include/CGAL/Bbox_2.h.

References Bbox_2(), max(), min(), xmax(), xmin(), ymax(), and ymin().

132 {
133  return Bbox_2(std::min(xmin(), b.xmin()),
134  std::min(ymin(), b.ymin()),
135  std::max(xmax(), b.xmax()),
136  std::max(ymax(), b.ymax()));
137 }
double ymin() const
double xmax() const
Vector_n max(const Array_n_const &v1, const Array_n_const &v2)
Definition: Vector_n.h:354
double xmin() const
Bbox_2()
Definition: Bbox_2.C:56
double ymax() const
Vector_n min(const Array_n_const &v1, const Array_n_const &v2)
Definition: Vector_n.h:346

Here is the call graph for this function:

Bbox_2& operator+= ( const Bbox_2 b)
inline

Definition at line 75 of file include/CGAL/Bbox_2.h.

References _max, _min, max(), and min().

75  {
76  _min[0] = std::min(_min[0], b._min[0]);
77  _min[1] = std::min(_min[1], b._min[1]);
78 
79  _max[0] = std::max(_max[0], b._max[0]);
80  _max[1] = std::max(_max[1], b._max[1]);
81 
82  return *this;
83  }
Vector_n max(const Array_n_const &v1, const Array_n_const &v2)
Definition: Vector_n.h:354
double _max[2]
Vector_n min(const Array_n_const &v1, const Array_n_const &v2)
Definition: Vector_n.h:346
double _min[2]

Here is the call graph for this function:

bool operator== ( const Bbox_2 b) const

Definition at line 66 of file Bbox_2.C.

References xmax(), xmin(), ymax(), and ymin().

67 {
68  return xmin() == b.xmin() && xmax() == b.xmax()
69  && ymin() == b.ymin() && ymax() == b.ymax();
70 }
double ymin() const
double xmax() const
double xmin() const
double ymax() const

Here is the call graph for this function:

double xmax ( ) const
inline

Definition at line 51 of file include/CGAL/Bbox_2.h.

References _max.

51 { return _max[0]; }
double _max[2]
double xmin ( ) const
inline

Definition at line 49 of file include/CGAL/Bbox_2.h.

References _min.

49 { return _min[0]; }
double _min[2]
double ymax ( ) const
inline

Definition at line 52 of file include/CGAL/Bbox_2.h.

References _max.

52 { return _max[1]; }
double _max[2]
double ymin ( ) const
inline

Definition at line 50 of file include/CGAL/Bbox_2.h.

References _min.

50 { return _min[1]; }
double _min[2]

Member Data Documentation

double _max[2]
private

Definition at line 85 of file include/CGAL/Bbox_2.h.

Referenced by Bbox_2(), operator+=(), xmax(), and ymax().

double _min[2]
private

Definition at line 85 of file include/CGAL/Bbox_2.h.

Referenced by Bbox_2(), operator+=(), xmin(), and ymin().


The documentation for this class was generated from the following files: