VTK  9.3.1
vtkYoungsMaterialInterface.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
25 #ifndef vtkYoungsMaterialInterface_h
26 #define vtkYoungsMaterialInterface_h
27 
28 #include "vtkFiltersGeneralModule.h" // For export macro
30 
31 #include "vtkSmartPointer.h" // For SP ivars
32 
33 VTK_ABI_NAMESPACE_BEGIN
34 class vtkIntArray;
35 class vtkInformation;
37 class vtkYoungsMaterialInterfaceInternals;
38 
39 class VTKFILTERSGENERAL_EXPORT vtkYoungsMaterialInterface : public vtkMultiBlockDataSetAlgorithm
40 {
41 public:
44  void PrintSelf(ostream& os, vtkIndent indent) override;
45 
47 
50  vtkSetMacro(InverseNormal, vtkTypeBool);
51  vtkGetMacro(InverseNormal, vtkTypeBool);
52  vtkBooleanMacro(InverseNormal, vtkTypeBool);
54 
56 
60  vtkSetMacro(ReverseMaterialOrder, vtkTypeBool);
61  vtkGetMacro(ReverseMaterialOrder, vtkTypeBool);
62  vtkBooleanMacro(ReverseMaterialOrder, vtkTypeBool);
64 
66 
70  vtkSetMacro(OnionPeel, vtkTypeBool);
71  vtkGetMacro(OnionPeel, vtkTypeBool);
72  vtkBooleanMacro(OnionPeel, vtkTypeBool);
74 
76 
80  vtkSetMacro(AxisSymetric, vtkTypeBool);
81  vtkGetMacro(AxisSymetric, vtkTypeBool);
82  vtkBooleanMacro(AxisSymetric, vtkTypeBool);
84 
86 
91  vtkSetMacro(UseFractionAsDistance, vtkTypeBool);
92  vtkGetMacro(UseFractionAsDistance, vtkTypeBool);
93  vtkBooleanMacro(UseFractionAsDistance, vtkTypeBool);
95 
97 
101  vtkSetMacro(FillMaterial, vtkTypeBool);
102  vtkGetMacro(FillMaterial, vtkTypeBool);
103  vtkBooleanMacro(FillMaterial, vtkTypeBool);
105 
107 
112  vtkSetVector2Macro(VolumeFractionRange, double);
113  vtkGetVectorMacro(VolumeFractionRange, double, 2);
115 
117 
120  virtual void SetNumberOfMaterials(int n);
121  virtual int GetNumberOfMaterials();
123 
125 
128  vtkSetMacro(UseAllBlocks, bool);
129  vtkGetMacro(UseAllBlocks, bool);
130  vtkBooleanMacro(UseAllBlocks, bool);
132 
134 
138  vtkGetMacro(NumberOfDomains, int);
140 
142 
146  virtual void SetMaterialArrays(int i, const char* volume, const char* normalX,
147  const char* normalY, const char* normalZ, const char* ordering);
148  virtual void SetMaterialArrays(
149  int i, const char* volume, const char* normal, const char* ordering);
150  virtual void SetMaterialVolumeFractionArray(int i, const char* volume);
151  virtual void SetMaterialNormalArray(int i, const char* normal);
152  virtual void SetMaterialOrderingArray(int i, const char* ordering);
154 
158  virtual void RemoveAllMaterials();
159 
161 
169  virtual void SetMaterialNormalArray(const char* volume, const char* normal);
170  virtual void SetMaterialOrderingArray(const char* volume, const char* ordering);
172 
174 
177  virtual void RemoveAllMaterialBlockMappings();
178  virtual void AddMaterialBlockMapping(int b);
180 
181  enum
182  {
183  MAX_CELL_POINTS = 256
184  };
185 
186 protected:
188  ~vtkYoungsMaterialInterface() override;
189 
190  int FillInputPortInformation(int port, vtkInformation* info) override;
191  int RequestData(vtkInformation* request, vtkInformationVector** inputVector,
192  vtkInformationVector* outputVector) override;
193 
197  virtual void Aggregate(int, int*);
198 
199  void UpdateBlockMapping();
200 
201  int CellProduceInterface(int dim, int np, double fraction, double minFrac, double maxFrac);
202 
204 
213  double VolumeFractionRange[2];
215 
217 
219 
224 
225  // Description:
226  // Internal data structures
227  vtkYoungsMaterialInterfaceInternals* Internals;
228 
229 private:
231  void operator=(const vtkYoungsMaterialInterface&) = delete;
232 };
233 
234 VTK_ABI_NAMESPACE_END
235 #endif /* VTK_YOUNGS_MATERIAL_INTERFACE_H */
vtkTypeBool UseFractionAsDistance
Read-Write Properties.
Store vtkAlgorithm input/output information.
vtkYoungsMaterialInterfaceInternals * Internals
int NumberOfDomains
Read only properties.
Superclass for algorithms that produce only vtkMultiBlockDataSet as output.
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.
static vtkMultiBlockDataSetAlgorithm * New()
int vtkTypeBool
Definition: vtkABI.h:64
dynamic, self-adjusting array of int
Definition: vtkIntArray.h:34
vtkTypeBool OnionPeel
Read-Write Properties.
a simple class to control print indentation
Definition: vtkIndent.h:28
vtkSmartPointer< vtkIntArray > MaterialBlockMapping
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
reconstructs material interfaces
vtkTypeBool ReverseMaterialOrder
Read-Write Properties.
Store zero or more vtkInformation instances.
vtkTypeBool FillMaterial
Read-Write Properties.
vtkTypeBool InverseNormal
Read-Write Properties.
vtkTypeBool AxisSymetric
Read-Write Properties.