34#include "vtkCommonDataModelModule.h"
65 void SetXMin(
double x,
double y,
double z);
67 void GetXMin(
double& x,
double& y,
double& z);
71 void SetXMax(
double x,
double y,
double z);
73 void GetXMax(
double& x,
double& y,
double& z);
75 void SetBounds(
double xMin,
double xMax,
double yMin,
double yMax,
double zMin,
double zMax);
78 double& xMin,
double& xMax,
double& yMin,
double& yMax,
double& zMin,
double& zMax);
99 static
char IntersectBox(const
double bounds[6], const
double origin[3], const
double dir[3],
100 double coord[3],
double& t, const
double tolerance = 0.0);
115 double& t1,
double& t2,
double x1[3],
double x2[3],
int& plane1,
int& plane2);
127 const
double p2[3],
double& t1,
double& t2,
double x1[3],
double x2[3],
int& plane1,
151 double bounds[6],
double origin[3],
double normal[3],
double xout[18]);
171 void operator=(const
vtkBox&) = delete;
176 this->
SetXMin(p[0], p[1], p[2]);
181 this->
SetXMax(p[0], p[1], p[2]);
Fast, simple class for representing and operating on 3D bounds.
void EvaluateGradient(double x[3], double n[3]) override
Evaluate the gradient of the box.
void SetBounds(double xMin, double xMax, double yMin, double yMax, double zMin, double zMax)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void SetBounds(const double bounds[6])
void SetXMax(double x, double y, double z)
void GetXMax(double &x, double &y, double &z)
static int IntersectWithLine(const double bounds[6], const double p1[3], const double p2[3], double &t1, double &t2, double x1[3], double x2[3], int &plane1, int &plane2)
Intersect a line with the box.
static char IntersectBox(const double bounds[6], const double origin[3], const double dir[3], double coord[3], double &t, const double tolerance=0.0)
Bounding box intersection with line modified from Graphics Gems Vol I.
static vtkTypeBool IsBoxInFrustum(double planes[24], double bounds[6])
Is a box in a frustum.
void GetXMax(double p[3])
void SetXMin(double x, double y, double z)
Set / get the bounding box using various methods.
static vtkTypeBool IntersectWithPlane(double bounds[6], double origin[3], double normal[3])
Plane intersection with the box.
static bool IntersectWithInfiniteLine(const double bounds[6], const double p1[3], const double p2[3], double &t1, double &t2, double x1[3], double x2[3], int &plane1, int &plane2)
Same method as vtkBox::IntersectWithLine, except that t1 and t2 can be outside of [0,...
void GetXMin(double &x, double &y, double &z)
Set / get the bounding box using various methods.
void GetXMin(double p[3])
Set / get the bounding box using various methods.
double EvaluateFunction(double x[3]) override
Evaluate function at position x-y-z and return value.
void SetXMin(double p[3])
Set / get the bounding box using various methods.
void SetXMax(double p[3])
void GetBounds(double bounds[6])
static vtkBox * New()
Construct box with center at (0,0,0) and each side of length 1.0.
void AddBounds(const double bounds[6])
A special method that allows union set operation on bounding boxes.
void GetBounds(double &xMin, double &xMax, double &yMin, double &yMax, double &zMin, double &zMax)
virtual double EvaluateFunction(double x[3])=0
Evaluate function at position x-y-z and return value.
a simple class to control print indentation
#define VTK_SIZEHINT(...)