VTK  9.3.1
vtkCompositeInterpolatedVelocityField.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
26 #ifndef vtkCompositeInterpolatedVelocityField_h
27 #define vtkCompositeInterpolatedVelocityField_h
28 
30 #include "vtkFiltersFlowPathsModule.h" // For export macro
31 
32 #include <array> // For array
33 #include <vector> // For vector
34 
35 VTK_ABI_NAMESPACE_BEGIN
36 class vtkDataSet;
37 
38 class VTKFILTERSFLOWPATHS_EXPORT vtkCompositeInterpolatedVelocityField
40 {
41 public:
43 
47  void PrintSelf(ostream& os, vtkIndent indent) override;
49 
54 
62  virtual void AddDataSet(vtkDataSet* dataset, size_t maxCellSize = 0);
63 
68  int FunctionValues(double* x, double* f) override;
69 
73  int InsideTest(double* x);
74 
83  virtual int SnapPointOnCell(double* pOrigin, double* pProj);
84 
88  void SetLastCellId(vtkIdType c, int dataindex) override;
89 
93  void SetLastCellId(vtkIdType c) override { this->Superclass::SetLastCellId(c); }
94 
96 
103  vtkGetMacro(LastDataSetIndex, int);
105 
107 
110  vtkGetMacro(CacheDataSetHit, int);
111  vtkGetMacro(CacheDataSetMiss, int);
113 
119 
120 protected:
123 
132  int FunctionValues(vtkDataSet* ds, double* x, double* f) override
133  {
134  return this->Superclass::FunctionValues(ds, x, f);
135  }
136 
141  {
143  std::array<double, 6> Bounds{};
146  };
147  std::vector<DataSetBoundsInformation> DataSetsBoundsInfo;
148 
149 private:
151  void operator=(const vtkCompositeInterpolatedVelocityField&) = delete;
152 };
153 
154 VTK_ABI_NAMESPACE_END
155 #endif
A helper class for interpolating between times during particle tracing.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:52
An abstract class for obtaining the interpolated velocity values at a point.
std::vector< DataSetBoundsInformation > DataSetsBoundsInfo
An abstract class for obtaining the interpolated velocity values at a point.
int vtkIdType
Definition: vtkType.h:315
void SetLastCellId(vtkIdType c) override
Set the cell id cached by the last evaluation.
virtual void CopyParameters(vtkAbstractInterpolatedVelocityField *from)
Copy essential parameters between instances of this class.
a simple class to control print indentation
Definition: vtkIndent.h:28
int FunctionValues(double *x, double *f) override=0
Evaluate the velocity field f at point (x, y, z).
virtual int FunctionValues(double *x, double *f)
Evaluate functions at x_j.
virtual void SetLastCellId(vtkIdType c)
Get/Set the id of the cell cached from last evaluation.
int FunctionValues(vtkDataSet *ds, double *x, double *f) override
Evaluate the velocity field f at point (x, y, z) in a specified dataset by either involving vtkPointL...
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for obtaining type information and printing the object state.
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...