33 #ifndef vtkUniformHyperTreeGrid_h
34 #define vtkUniformHyperTreeGrid_h
42 #include "vtkCommonDataModelModule.h"
72 vtkSetVector3Macro(Origin,
double);
73 vtkGetVector3Macro(Origin,
double);
80 void SetGridScale(
double,
double,
double);
81 void SetGridScale(
double*);
82 vtkGetVector3Macro(GridScale,
double);
88 void SetGridScale(
double);
103 void SetXCoordinates(
vtkDataArray* XCoordinates) override;
118 void SetYCoordinates(
vtkDataArray* YCoordinates) override;
133 void SetZCoordinates(
vtkDataArray* ZCoordinates) override;
148 void SetFixedCoordinates(
unsigned int axis,
double value) override;
154 void GetLevelZeroOriginAndSizeFromIndex(
vtkIdType,
double*,
double*) override;
159 void GetLevelZeroOriginFromIndex(vtkIdType,
double*) override;
174 unsigned long GetActualMemorySizeBytes() override;
180 vtkHyperTree* GetTree(vtkIdType,
bool create = false) override;
191 ~vtkUniformHyperTreeGrid() override;
207 bool ComputedXCoordinates;
208 bool ComputedYCoordinates;
209 bool ComputedZCoordinates;
212 unsigned int FindDichotomicX(
double value)
const override
214 if (value < this->Origin[0] ||
215 value > this->Origin[0] + this->GridScale[0] * (this->
GetDimensions()[0] - 1))
219 return std::round((value - this->Origin[0]) / this->GridScale[0]);
223 if (value < this->Origin[1] ||
224 value > this->Origin[1] + this->GridScale[1] * (this->
GetDimensions()[1] - 1))
228 return std::round((value - this->Origin[1]) / this->GridScale[1]);
232 if (value < this->Origin[2] ||
233 value > this->Origin[2] + this->GridScale[2] * (this->
GetDimensions()[2] - 1))
237 return std::round((value - this->Origin[2]) / this->GridScale[2]);
243 mutable std::shared_ptr<vtkHyperTreeGridScales>
Scales;
void Initialize() override
Restore data object to initial state.
virtual double * GetBounds()
Return a pointer to the geometry bounding box in the form (xmin,xmax, ymin,ymax, zmin,zmax).
A dataset containing a grid of vtkHyperTree instances arranged as a rectilinear grid.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
dynamic, self-adjusting array of double
static vtkHyperTreeGrid * New()
a simple class to control print indentation
#define VTK_UNIFORM_HYPER_TREE_GRID
abstract superclass for arrays of numeric data
const unsigned int * GetDimensions() const
Get dimensions of this rectilinear grid dataset.
#define VTK_SIZEHINT(...)
virtual void CopyStructure(vtkDataObject *)
Copy the internal geometric and topological structure of a vtkHyperTreeGrid object.
A data object structured as a tree.
A specifalized type of vtkHyperTreeGrid for the case when root cells have uniform sizes in each direc...
general representation of visualization data