Go to the documentation of this file.
29 #ifndef vtkBoundingBox_h
30 #define vtkBoundingBox_h
43 double yMin,
double yMax,
44 double zMin,
double zMax);
62 void SetBounds(
const double bounds[6]);
64 double yMin,
double yMax,
65 double zMin,
double zMax);
72 void SetMinPoint(
double p[3]);
79 void SetMaxPoint(
double p[3]);
86 void AddPoint(
double px,
double py,
double pz);
119 void GetBounds(
double bounds[6])
const;
120 void GetBounds(
double &xMin,
double &xMax,
121 double &yMin,
double &yMax,
122 double &zMin,
double &zMax)
const;
126 double GetBound(
int i)
const;
130 const double *GetMinPoint()
const;
131 void GetMinPoint(
double &
x,
double &
y,
double &
z)
const;
136 const double *GetMaxPoint()
const;
137 void GetMaxPoint(
double &
x,
double &
y,
double &
z)
const;
142 int ContainsPoint(
double p[3])
const;
143 int ContainsPoint(
double px,
double py,
double pz)
const;
147 void GetCenter(
double center[3])
const;
150 void GetLengths(
double lengths[3])
const;
153 double GetLength(
int i)
const;
169 static int IsValid(
const double bounds[6]);
187 double MinPnt[3], MaxPnt[3];
197 double &yMin,
double &yMax,
198 double &zMin,
double &zMax)
const
213 return ((i & 0x1) ? this->
MaxPnt[i>>1] : this->
MinPnt[i>>1]);
235 return (bounds[0] <= bounds[1] &&
236 bounds[2] <= bounds[3] &&
237 bounds[4] <= bounds[5]);
261 this->
SetBounds(bounds[0], bounds[1], bounds[2],
262 bounds[3], bounds[4], bounds[5]);
267 this->
GetBounds(bounds[0], bounds[1], bounds[2],
268 bounds[3], bounds[4], bounds[5]);
283 double yMin,
double yMax,
284 double zMin,
double zMax)
287 this->
SetBounds(xMin, xMax, yMin, yMax, zMin, zMax);
316 (this->MinPnt[1] == bbox.
MinPnt[1]) &&
317 (this->MinPnt[2] == bbox.
MinPnt[2]) &&
318 (this->MaxPnt[0] == bbox.
MaxPnt[0]) &&
319 (this->MaxPnt[1] == bbox.
MaxPnt[1]) &&
320 (this->MaxPnt[2] == bbox.
MaxPnt[2]));
325 return !((*this) == bbox);
vtkBoundingBox & operator=(const vtkBoundingBox &bbox)
double GetDiagonalLength() const
const double * GetMaxPoint() const
int IntersectBox(const vtkBoundingBox &bbox)
GLint GLint GLint GLint GLint x
void SetMinPoint(double x, double y, double z)
void GetLengths(double lengths[3]) const
int operator==(const vtkBoundingBox &bbox) const
void Inflate(double delta)
Fast Simple Class for dealing with 3D bounds.
void SetMaxPoint(double x, double y, double z)
void SetBounds(double xMin, double xMax, double yMin, double yMax, double zMin, double zMax)
void AddBounds(const double bounds[])
void SetBounds(const double bounds[6])
void GetBounds(double bounds[6]) const
double GetMaxLength() const
const double * GetMinPoint() const
void GetCenter(double center[3]) const
int Contains(const vtkBoundingBox &bbox) const
int operator!=(const vtkBoundingBox &bbox) const
double GetLength(int i) const
VTKCOMMONCORE_EXPORT bool operator==(const vtkUnicodeString &lhs, const vtkUnicodeString &rhs)
void AddPoint(double p[3])
void AddPoint(double px, double py, double pz)
void Scale(double sx, double sy, double sz)
GLsizei GLenum GLenum GLuint GLenum GLsizei * lengths
GLint GLint GLint GLint GLint GLint y
int ContainsPoint(double p[3]) const
int Intersects(const vtkBoundingBox &bbox) const
#define VTKCOMMONDATAMODEL_EXPORT
bool IntersectPlane(double origin[3], double normal[3])
VTKCOMMONCORE_EXPORT bool operator!=(const vtkUnicodeString &lhs, const vtkUnicodeString &rhs)
double GetBound(int i) const
void AddBox(const vtkBoundingBox &bbox)