VTK
vtkHyperOctreeCursor.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkHyperOctreeCursor.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 =========================================================================*/
24 #ifndef vtkHyperOctreeCursor_h
25 #define vtkHyperOctreeCursor_h
26 
27 #include "vtkCommonDataModelModule.h" // For export macro
28 #include "vtkObject.h"
29 
30 enum
31 {
40 };
41 
46 
49 
51 {
52 public:
54  void PrintSelf(ostream& os, vtkIndent indent);
55 
58  virtual int GetLeafId()=0;
59 
61  virtual int CurrentIsLeaf()=0;
62 
64  virtual int CurrentIsRoot()=0;
65 
68  virtual int GetCurrentLevel()=0;
69 
73  virtual int GetChildIndex()=0;
74 
75  // Are the children of the current node all leaves?
76  // This query can be called also on a leaf node.
77  // \post compatible: result implies !CurrentIsLeaf()
78  virtual int CurrentIsTerminalNode()=0;
79 
82  virtual void ToRoot()=0;
83 
86  virtual void ToParent()=0;
87 
91  virtual void ToChild(int child)=0;
92 
96  virtual void ToSameNode(vtkHyperOctreeCursor *other)=0;
97 
100  virtual int IsEqual(vtkHyperOctreeCursor *other)=0;
101 
105 
108  virtual int SameTree(vtkHyperOctreeCursor *other)=0;
109 
114  virtual int GetIndex(int d)=0;
115 
118  virtual int GetNumberOfChildren()=0;
119 
121  virtual int GetDimension()=0;
122 
124 
130  virtual void MoveToNode(int *indices,
131  int level)=0;
133 
135  virtual int Found()=0;
136 
137 protected:
138  // Constructor.
141 private:
142  vtkHyperOctreeCursor(const vtkHyperOctreeCursor&); // Not implemented.
143  void operator=(const vtkHyperOctreeCursor&); // Not implemented.
144 };
145 #endif
VTK_OCTREE_CHILD_ZMIN_YMAX_XMIN
@ VTK_OCTREE_CHILD_ZMIN_YMAX_XMIN
Definition: vtkHyperOctreeCursor.h:34
vtkHyperOctreeCursor::GetDimension
virtual int GetDimension()=0
vtkHyperOctreeCursor::IsEqual
virtual int IsEqual(vtkHyperOctreeCursor *other)=0
vtkCommonDataModelModule.h
vtkHyperOctreeCursor::CurrentIsTerminalNode
virtual int CurrentIsTerminalNode()=0
VTK_OCTREE_CHILD_ZMAX_YMAX_XMAX
@ VTK_OCTREE_CHILD_ZMAX_YMAX_XMAX
Definition: vtkHyperOctreeCursor.h:39
VTK_OCTREE_CHILD_ZMAX_YMIN_XMIN
@ VTK_OCTREE_CHILD_ZMAX_YMIN_XMIN
Definition: vtkHyperOctreeCursor.h:36
vtkTypeMacro
#define vtkTypeMacro(thisClass, superclass)
Definition: vtkSetGet.h:642
vtkHyperOctreeCursor
Objects that can traverse hyperoctree nodes.
Definition: vtkHyperOctreeCursor.h:51
vtkObject
abstract base class for most VTK objects
Definition: vtkObject.h:62
VTK_QUADTREE_CHILD_SE
const int VTK_QUADTREE_CHILD_SE
Definition: vtkHyperOctreeCursor.h:43
vtkHyperOctreeCursor::GetNumberOfChildren
virtual int GetNumberOfChildren()=0
VTK_QUADTREE_CHILD_NW
const int VTK_QUADTREE_CHILD_NW
Definition: vtkHyperOctreeCursor.h:44
vtkHyperOctreeCursor::SameTree
virtual int SameTree(vtkHyperOctreeCursor *other)=0
VTK_BINARY_TREE_CHILD_LEFT
const int VTK_BINARY_TREE_CHILD_LEFT
Definition: vtkHyperOctreeCursor.h:47
vtkHyperOctreeCursor::vtkHyperOctreeCursor
vtkHyperOctreeCursor()
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:39
VTK_OCTREE_CHILD_ZMAX_YMAX_XMIN
@ VTK_OCTREE_CHILD_ZMAX_YMAX_XMIN
Definition: vtkHyperOctreeCursor.h:38
vtkgl::indices
GLuint GLuint GLsizei GLenum const GLvoid * indices
Definition: vtkgl.h:11315
VTK_QUADTREE_CHILD_SW
const int VTK_QUADTREE_CHILD_SW
Definition: vtkHyperOctreeCursor.h:42
vtkHyperOctreeCursor::Clone
virtual vtkHyperOctreeCursor * Clone()=0
vtkHyperOctreeCursor::ToParent
virtual void ToParent()=0
vtkHyperOctreeCursor::CurrentIsLeaf
virtual int CurrentIsLeaf()=0
vtkHyperOctreeCursor::ToSameNode
virtual void ToSameNode(vtkHyperOctreeCursor *other)=0
vtkHyperOctreeCursor::GetChildIndex
virtual int GetChildIndex()=0
vtkgl::level
GLint level
Definition: vtkgl.h:11316
vtkObject.h
vtkHyperOctreeCursor::ToRoot
virtual void ToRoot()=0
vtkHyperOctreeCursor::CurrentIsRoot
virtual int CurrentIsRoot()=0
vtkHyperOctreeCursor::~vtkHyperOctreeCursor
virtual ~vtkHyperOctreeCursor()
VTK_BINARY_TREE_CHILD_RIGHT
const int VTK_BINARY_TREE_CHILD_RIGHT
Definition: vtkHyperOctreeCursor.h:48
vtkHyperOctreeCursor::GetCurrentLevel
virtual int GetCurrentLevel()=0
vtkHyperOctreeCursor::Found
virtual int Found()=0
VTK_OCTREE_CHILD_ZMIN_YMIN_XMIN
@ VTK_OCTREE_CHILD_ZMIN_YMIN_XMIN
Definition: vtkHyperOctreeCursor.h:32
vtkHyperOctreeCursor::GetIndex
virtual int GetIndex(int d)=0
vtkHyperOctreeCursor::MoveToNode
virtual void MoveToNode(int *indices, int level)=0
vtkHyperOctreeCursor::ToChild
virtual void ToChild(int child)=0
VTK_OCTREE_CHILD_ZMIN_YMAX_XMAX
@ VTK_OCTREE_CHILD_ZMIN_YMAX_XMAX
Definition: vtkHyperOctreeCursor.h:35
VTKCOMMONDATAMODEL_EXPORT
#define VTKCOMMONDATAMODEL_EXPORT
Definition: vtkCommonDataModelModule.h:15
VTK_OCTREE_CHILD_ZMAX_YMIN_XMAX
@ VTK_OCTREE_CHILD_ZMAX_YMIN_XMAX
Definition: vtkHyperOctreeCursor.h:37
VTK_QUADTREE_CHILD_NE
const int VTK_QUADTREE_CHILD_NE
Definition: vtkHyperOctreeCursor.h:45
vtkHyperOctreeCursor::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent)
VTK_OCTREE_CHILD_ZMIN_YMIN_XMAX
@ VTK_OCTREE_CHILD_ZMIN_YMIN_XMAX
Definition: vtkHyperOctreeCursor.h:33
vtkHyperOctreeCursor::GetLeafId
virtual int GetLeafId()=0