VTK  9.0.1
vtkHyperTreeGridOrientedCursor.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkHyperTreeGridOrientedCursor.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 =========================================================================*/
38 #ifndef vtkHyperTreeGridOrientedCursor_h
39 #define vtkHyperTreeGridOrientedCursor_h
40 
41 #include "vtkCommonDataModelModule.h" // For export macro
42 #include "vtkHyperTreeGridEntry.h" // Used internally
43 #include "vtkObject.h"
44 
45 class vtkHyperTree;
46 class vtkHyperTreeGrid;
47 
48 class VTKCOMMONDATAMODEL_EXPORT vtkHyperTreeGridOrientedCursor : public vtkObject
49 {
50 public:
52  void PrintSelf(ostream& os, vtkIndent indent) override;
54 
60 
64  void Initialize(vtkHyperTreeGrid* grid, vtkIdType treeIndex, bool create = false);
65 
69  void Initialize(vtkHyperTreeGrid* grid, vtkHyperTree* tree, unsigned int level, vtkIdType index);
70 
74  void Initialize(
75  vtkHyperTreeGrid* grid, vtkHyperTree* tree, unsigned int level, vtkHyperTreeGridEntry& entry);
76 
78 
83 
85 
88  bool HasTree() const;
90 
92 
97 
102 
108 
113  unsigned char GetDimension();
114 
119  unsigned char GetNumberOfChildren();
120 
125 
130 
135  void SetMask(bool state);
136 
140  bool IsMasked();
141 
145  bool IsLeaf();
146 
151 
155  bool IsRoot();
156 
160  unsigned int GetLevel();
161 
169  void ToChild(unsigned char ichild);
170 
171 protected:
176 
181 
186 
191 
195  unsigned int Level;
196 
197  // Hyper tree grid to which the cursor is attached
199 
200 private:
202  void operator=(const vtkHyperTreeGridOrientedCursor&) = delete;
203 };
204 #endif
vtkHyperTreeGridOrientedCursor::SubdivideLeaf
void SubdivideLeaf()
JB Fait chier normalement on devrait passer par GetEntry.
vtkHyperTreeGridOrientedCursor::SetMask
void SetMask(bool state)
Set the blanking mask is empty or not.
vtkHyperTreeGridOrientedCursor::GetLevel
unsigned int GetLevel()
Get the level of the tree vertex pointed by the cursor.
vtkHyperTreeGridOrientedCursor::GetGrid
vtkHyperTreeGrid * GetGrid()
Set the hyper tree grid to which the cursor is pointing.
vtkHyperTreeGridOrientedCursor::IsRoot
bool IsRoot()
Is the cursor at tree root?
vtkIdType
int vtkIdType
Definition: vtkType.h:338
vtkHyperTreeGridOrientedCursor::vtkHyperTreeGridOrientedCursor
vtkHyperTreeGridOrientedCursor()
Constructor.
vtkObject
abstract base class for most VTK objects
Definition: vtkObject.h:54
vtkHyperTreeGridOrientedCursor::Grid
vtkHyperTreeGrid * Grid
JB Reference sur l'hyper tree grid parcouru actuellement.
Definition: vtkHyperTreeGridOrientedCursor.h:185
vtkHyperTreeGridOrientedCursor::Tree
vtkHyperTree * Tree
JB.
Definition: vtkHyperTreeGridOrientedCursor.h:190
vtkHyperTreeGridOrientedCursor::GetGlobalNodeIndex
vtkIdType GetGlobalNodeIndex()
Return the global index (relative to the grid) of the current vertex in the tree.
vtkHyperTreeGridOrientedCursor::SetGlobalIndexFromLocal
void SetGlobalIndexFromLocal(vtkIdType index)
JB.
vtkX3D::level
@ level
Definition: vtkX3D.h:401
vtkHyperTreeGridOrientedCursor::GetNumberOfChildren
unsigned char GetNumberOfChildren()
Return the number of children for each node (non-vertex leaf) of the tree.
vtkHyperTreeGridOrientedCursor::~vtkHyperTreeGridOrientedCursor
~vtkHyperTreeGridOrientedCursor() override
Destructor.
vtkHyperTreeGridOrientedCursor::New
static vtkHyperTreeGridOrientedCursor * New()
vtkHyperTreeGridOrientedCursor::GetDimension
unsigned char GetDimension()
Return the dimension of the tree.
vtkHyperTreeGridOrientedCursor::GetTree
vtkHyperTree * GetTree() const
Set the hyper tree to which the cursor is pointing.
vtkHyperTreeGridOrientedCursor::ToChild
void ToChild(unsigned char ichild)
Move the cursor to child ‘child’ of the current vertex.
vtkHyperTreeGridOrientedCursor::Clone
vtkHyperTreeGridOrientedCursor * Clone()
Create a copy of ‘this’.
vtkHyperTreeGridOrientedCursor::Entry
vtkHyperTreeGridEntry Entry
Definition: vtkHyperTreeGridOrientedCursor.h:198
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:34
vtkHyperTree
A data object structured as a tree.
Definition: vtkHyperTree.h:179
vtkHyperTreeGridOrientedCursor::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkObject.h
vtkHyperTreeGridEntry
Entries are cache data for cursors.
Definition: vtkHyperTreeGridEntry.h:75
vtkHyperTreeGridOrientedCursor
Objects for traversal a HyperTreeGrid.
Definition: vtkHyperTreeGridOrientedCursor.h:49
vtkHyperTreeGridOrientedCursor::IsMasked
bool IsMasked()
Determine whether blanking mask is empty or not.
vtkHyperTreeGridOrientedCursor::Level
unsigned int Level
JB.
Definition: vtkHyperTreeGridOrientedCursor.h:195
vtkHyperTreeGridOrientedCursor::SetGlobalIndexStart
void SetGlobalIndexStart(vtkIdType index)
JB.
vtkHyperTreeGridOrientedCursor::IsLeaf
bool IsLeaf()
Is the cursor pointing to a leaf?
vtkHyperTreeGridOrientedCursor::GetVertexId
vtkIdType GetVertexId()
Return the index of the current vertex in the tree.
vtkHyperTreeGridEntry.h
vtkX3D::index
@ index
Definition: vtkX3D.h:252
vtkHyperTreeGridOrientedCursor::Initialize
void Initialize(vtkHyperTreeGrid *grid, vtkHyperTree *tree, unsigned int level, vtkHyperTreeGridEntry &entry)
JB.
vtkHyperTreeGridOrientedCursor::Initialize
void Initialize(vtkHyperTreeGrid *grid, vtkIdType treeIndex, bool create=false)
Initialize cursor at root of given tree index in grid.
vtkHyperTreeGridOrientedCursor::HasTree
bool HasTree() const
Return if a Tree pointing exist.
vtkHyperTreeGrid
A dataset containing a grid of vtkHyperTree instances arranged as a rectilinear grid.
Definition: vtkHyperTreeGrid.h:97
vtkHyperTreeGridOrientedCursor::Initialize
void Initialize(vtkHyperTreeGrid *grid, vtkHyperTree *tree, unsigned int level, vtkIdType index)
JB.