Go to the documentation of this file.
40 #ifndef vtkCellTreeLocator_h
41 #define vtkCellTreeLocator_h
43 #include "vtkFiltersGeneralModule.h"
47 class vtkCellPointTraversal;
71 double* weights )
override;
78 double& t,
double x[3],
double pcoords[3],
100 int IntersectWithLine(
const double p1[3],
const double p2[3],
double tol,
double& t,
double x[3],
101 double pcoords[3],
int &subId)
override
103 return this->Superclass::IntersectWithLine(p1, p2, tol, t, x, pcoords, subId);
112 int IntersectWithLine(
const double p1[3],
const double p2[3],
double tol,
double &t,
double x[3],
113 double pcoords[3],
int &subId,
vtkIdType &cellId)
override;
119 const double p1[3],
const double p2[3],
122 return this->Superclass::IntersectWithLine(p1, p2,
points, cellIds);
129 {
return this->Superclass::FindCell(x); }
137 virtual void BuildLocatorInternal();
138 virtual void BuildLocatorIfNeeded();
139 virtual void ForceBuildLocator();
153 friend class vtkCellPointTraversal;
155 friend class vtkCellTreeBuilder;
185 friend class vtkCellPointTraversal;
186 friend class vtkCellTreeBuilder;
189 void MakeNode(
unsigned int left,
unsigned int d,
float b[2] );
190 void SetChildren(
unsigned int left );
192 unsigned int GetLeftChildIndex()
const;
193 unsigned int GetRightChildIndex()
const;
194 unsigned int GetDimension()
const;
195 const float& GetLeftMaxValue()
const;
196 const float& GetRightMinValue()
const;
197 void MakeLeaf(
unsigned int start,
unsigned int size );
199 unsigned int Start()
const;
200 unsigned int Size()
const;
208 bool RayMinMaxT(
const double origin[3],
213 bool RayMinMaxT(
const double bounds[6],
214 const double origin[3],
219 int getDominantAxis(
const double dir[3]);
222 void Classify(
const double origin[3],
233 virtual int IntersectCellInternal(
vtkIdType cell_ID,
const double p1[3],
246 friend class vtkCellPointTraversal;
248 friend class vtkCellTreeBuilder;
represent and manipulate 3D points
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
Internal classes made public to allow subclasses to create customized some traversal algorithms.
std::vector< vtkCellTreeNode > Nodes
vtkIdType FindCell(double x[3]) override
reimplemented from vtkAbstractCellLocator to support bad compilers
This class is the basic building block of the cell tree.
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
virtual vtkIdType FindCell(double x[3])
Returns the Id of the cell containing the point, returns -1 if no cell found.
virtual void FindCellsWithinBounds(double *bbox, vtkIdList *cells)
Return a list of unique cell ids inside of a given bounding box.
int IntersectWithLine(const double p1[3], const double p2[3], double tol, double &t, double x[3], double pcoords[3], int &subId) override
reimplemented from vtkAbstractCellLocator to support bad compilers
virtual void GenerateRepresentation(int level, vtkPolyData *pd)=0
Method to build a representation at a particular level.
a simple class to control print indentation
object to represent cell connectivity
list of point or cell ids
virtual void BuildLocator()=0
Build the locator from the input dataset.
an abstract base class for locators which find cells
int IntersectWithLine(const double p1[3], const double p2[3], vtkPoints *points, vtkIdList *cellIds) override
reimplemented from vtkAbstractCellLocator to support bad compilers
virtual int IntersectWithLine(const double p1[3], const double p2[3], double tol, double &t, double x[3], double pcoords[3], int &subId)
Return intersection point (if any) of finite line with cells contained in cell locator.
dynamic, self-adjusting array of vtkIdType
concrete dataset represents vertices, lines, polygons, and triangle strips
provides thread-safe access to cells
std::vector< unsigned int > Leaves
This class implements the data structures, construction algorithms for fast cell location presented i...
virtual void FreeSearchStructure()=0
Free the memory required for the spatial data structure.