VTK
vtkOverlappingAMR.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkOverlappingAMR.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
33 #ifndef vtkOverlappingAmr_h
34 #define vtkOverlappingAmr_h
35 
36 #include "vtkCommonDataModelModule.h" // For export macro
37 #include "vtkUniformGridAMR.h"
38 
39 class vtkAMRBox;
41 class vtkUniformGrid;
42 class vtkAMRInformation;
44 
46 {
47 public:
48  static vtkOverlappingAMR *New();
49 
51  virtual int GetDataObjectType() {return VTK_OVERLAPPING_AMR;}
52 
54  void PrintSelf(ostream& os, vtkIndent indent);
55 
58 
60 
61  void SetOrigin(const double*);
62  double* GetOrigin();
64 
66 
67  void SetSpacing(unsigned int level, const double spacing[3]);
68  void GetSpacing(unsigned int level, double spacing[3]);
70 
72 
73  void SetAMRBox(unsigned int level, unsigned int id, const vtkAMRBox& box) ;
74  const vtkAMRBox& GetAMRBox(unsigned int level, unsigned int id) ;
76 
78  void GetBounds(unsigned int level, unsigned int id, double* bb);
79 
80 
82  void GetOrigin(unsigned int level, unsigned int id, double origin[3]);
83 
84  static vtkInformationIdTypeKey* NUMBER_OF_BLANKED_POINTS();
85 
86  //BTX
88 
90  { return vtkOverlappingAMR::SafeDownCast(Superclass::GetData(info)); }
92  { return vtkOverlappingAMR::SafeDownCast(Superclass::GetData(v, i)); }
93  //ETX
95 
102  void SetRefinementRatio(unsigned int level, int refRatio);
103 
105  int GetRefinementRatio(unsigned int level);
106 
108 
110  void SetAMRBlockSourceIndex(unsigned int level, unsigned int id, int sourceId);
111  int GetAMRBlockSourceIndex(unsigned int level, unsigned int id);
113 
116  int GetRefinementRatio(vtkCompositeDataIterator* iter);
117 
119  bool HasChildrenInformation();
120 
123  void GenerateParentChildInformation();
124 
128  unsigned int *GetParents(unsigned int level, unsigned int index, unsigned int& numParents);
129 
133  unsigned int *GetChildren(unsigned int level, unsigned int index, unsigned int& numChildren);
134 
136  void PrintParentChildInfo(unsigned int level, unsigned int index);
137 
138  //Unhide superclass method
139  void GetBounds(double b[6]) { Superclass::GetBounds(b);}
140 
142  bool FindGrid(double q[3], unsigned int& level, unsigned int& gridId);
143 
145 
146  vtkAMRInformation* GetAMRInfo(){ return Superclass::GetAMRInfo();}
147  virtual void SetAMRInfo(vtkAMRInformation* info){ return Superclass::SetAMRInfo(info);}
149 
151 
154  void Audit();
155  protected:
157  virtual ~vtkOverlappingAMR();
159 
160 private:
161  vtkOverlappingAMR(const vtkOverlappingAMR&); // Not implemented.
162  void operator=(const vtkOverlappingAMR&); // Not implemented.
163 };
164 
165 #endif
const double * GetBounds()
static vtkUniformGridAMR * New()
void PrintSelf(ostream &os, vtkIndent indent)
virtual void SetAMRInfo(vtkAMRInformation *info)
Store vtkAlgorithm input/output information.
Encloses a rectangular region of voxel like cells.
Definition: vtkAMRBox.h:38
superclass for composite data iterators
Meta data that describes the structure of an AMR data set.
a simple class to control print indentation
Definition: vtkIndent.h:38
virtual vtkCompositeDataIterator * NewIterator()
static vtkOverlappingAMR * SafeDownCast(vtkObjectBase *o)
virtual int GetDataObjectType()
image data with blanking
static vtkOverlappingAMR * GetData(vtkInformation *info)
vtkAMRInformation * GetAMRInfo()
hierarchical dataset of vtkUniformGrids
Store zero or more vtkInformation instances.
#define VTK_OVERLAPPING_AMR
Definition: vtkType.h:97
VTKWRAPPINGJAVA_EXPORT jlong q(JNIEnv *env, jobject obj)
Key for vtkIdType values in vtkInformation.
static vtkOverlappingAMR * GetData(vtkInformationVector *v, int i=0)
#define VTKCOMMONDATAMODEL_EXPORT
void GetBounds(double b[6])