VTK
vtkAMRInterpolatedVelocityField.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkAMRInterpolatedVelocityField.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 =========================================================================*/
25 #ifndef vtkAMRInterpolatedVelocityField_h
26 #define vtkAMRInterpolatedVelocityField_h
27 
28 #include "vtkFiltersFlowPathsModule.h" // For export macro
29 
31 
32 class vtkOverlappingAMR;
33 
34 class VTKFILTERSFLOWPATHS_EXPORT vtkAMRInterpolatedVelocityField
36 {
37 public:
38  vtkTypeMacro( vtkAMRInterpolatedVelocityField,
40 
42 
43  vtkGetMacro(AmrDataSet,vtkOverlappingAMR*);
44  void SetAMRData(vtkOverlappingAMR* amr);
45 
46  bool GetLastDataSetLocation(unsigned int& level, unsigned int& id);
47 
48  bool SetLastDataSet(int level, int id);
49 
50  void SetLastCellId( vtkIdType c, int dataindex ) override;
51 
55  void SetLastCellId( vtkIdType c ) override
56  { this->Superclass::SetLastCellId( c ); }
57 
69  int FunctionValues( double * x, double * f ) override;
70 
71  void PrintSelf( ostream & os, vtkIndent indent ) override;
72 
73  // Descriptino:
74  // Point location routine.
75  static bool FindGrid(double q[3],vtkOverlappingAMR *amrds, unsigned int& level, unsigned int& gridId);
76 
77 protected:
79  int LastLevel;
80  int LastId;
81 
84  int FunctionValues( vtkDataSet * ds, double * x, double * f ) override
85  { return this->Superclass::FunctionValues( ds, x, f ); }
86 
87 private:
89  void operator = ( const vtkAMRInterpolatedVelocityField& ) = delete;
90 
91 };
92 
93 #endif
abstract class to specify dataset behavior
Definition: vtkDataSet.h:56
int FunctionValues(vtkDataSet *ds, double *x, double *f) override
Evaluate the velocity field f at point (x, y, z) in a specified dataset by invoking vtkDataSet::FindC...
An abstract class for obtaining the interpolated velocity values at a point.
int vtkIdType
Definition: vtkType.h:345
virtual int FunctionValues(double *x, double *f)=0
Evaluate functions at x_j.
a simple class to control print indentation
Definition: vtkIndent.h:33
int FunctionValues(double *x, double *f) override=0
Evaluate the velocity field f at point (x, y, z).
void SetLastCellId(vtkIdType c) override
Set the cell id cached by the last evaluation.
virtual void SetLastCellId(vtkIdType c)
Get/Set the id of the cell cached from last evaluation.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
hierarchical dataset of vtkUniformGrids
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
A concrete class for obtaining the interpolated velocity values at a point in AMR data.