VTK  9.0.1
vtkAMRUtilities.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkAMRUtilities.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  =========================================================================*/
26 #ifndef vtkAMRUtilities_h
27 #define vtkAMRUtilities_h
28 
29 #include "vtkCommonDataModelModule.h" // For export macro
30 #include "vtkObject.h"
31 #include <vector> // For C++ vector
32 
33 // Forward declarations
34 class vtkFieldData;
35 class vtkOverlappingAMR;
36 class vtkUniformGrid;
37 
38 class VTKCOMMONDATAMODEL_EXPORT vtkAMRUtilities : public vtkObject
39 {
40 public:
41  // Standard Routines
42  vtkTypeMacro(vtkAMRUtilities, vtkObject);
43  void PrintSelf(ostream& os, vtkIndent indent) override;
44 
54  static void StripGhostLayers(
55  vtkOverlappingAMR* ghostedAMRData, vtkOverlappingAMR* strippedAMRData);
56 
63  static bool HasPartiallyOverlappingGhostCells(vtkOverlappingAMR* amr);
64 
68  static void BlankCells(vtkOverlappingAMR* amr);
69 
70 protected:
72  ~vtkAMRUtilities() override {}
73 
78  static void CopyFieldsWithinRealExtent(
79  int realExtent[6], vtkUniformGrid* ghostedGrid, vtkUniformGrid* strippedGrid);
80 
84  static void CopyFieldData(
85  vtkFieldData* target, vtkIdType targetIdx, vtkFieldData* source, vtkIdType sourceIdx);
86 
94  static vtkUniformGrid* StripGhostLayersFromGrid(vtkUniformGrid* grid, int ghost[6]);
95 
96  static void BlankGridsAtLevel(vtkOverlappingAMR* amr, int levelIdx,
97  std::vector<std::vector<unsigned int> >& children, const std::vector<int>& processMap);
98 
99 private:
100  vtkAMRUtilities(const vtkAMRUtilities&) = delete;
101  void operator=(const vtkAMRUtilities&) = delete;
102 };
103 
104 #endif /* vtkAMRUtilities_h */
vtkX3D::vector
@ vector
Definition: vtkX3D.h:243
vtkIdType
int vtkIdType
Definition: vtkType.h:338
vtkUniformGrid
image data with blanking
Definition: vtkUniformGrid.h:34
vtkObject
abstract base class for most VTK objects
Definition: vtkObject.h:62
vtkAMRUtilities
Definition: vtkAMRUtilities.h:38
vtkFieldData
represent and manipulate fields of data
Definition: vtkFieldData.h:53
target
boost::graph_traits< vtkGraph * >::vertex_descriptor target(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
Definition: vtkBoostGraphAdapter.h:965
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkAMRUtilities::vtkAMRUtilities
vtkAMRUtilities()
Definition: vtkAMRUtilities.h:71
vtkObject::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkOverlappingAMR
hierarchical dataset of vtkUniformGrids
Definition: vtkOverlappingAMR.h:40
vtkObject.h
source
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
Definition: vtkBoostGraphAdapter.h:959
vtkAMRUtilities::~vtkAMRUtilities
~vtkAMRUtilities() override
Definition: vtkAMRUtilities.h:72