VTK
vtkImplicitDataSet.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImplicitDataSet.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 =========================================================================*/
43 #ifndef vtkImplicitDataSet_h
44 #define vtkImplicitDataSet_h
45 
46 #include "vtkCommonDataModelModule.h" // For export macro
47 #include "vtkImplicitFunction.h"
48 
49 class vtkDataSet;
50 
51 class VTKCOMMONDATAMODEL_EXPORT vtkImplicitDataSet : public vtkImplicitFunction
52 {
53 public:
55  void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
56 
61  static vtkImplicitDataSet *New();
62 
66  vtkMTimeType GetMTime() VTK_OVERRIDE;
67 
69 
73  double EvaluateFunction(double x[3]) VTK_OVERRIDE;
74  double EvaluateFunction(double x, double y, double z)
75  {return this->vtkImplicitFunction::EvaluateFunction(x, y, z); } ;
77 
81  void EvaluateGradient(double x[3], double n[3]) VTK_OVERRIDE;
82 
84 
87  virtual void SetDataSet(vtkDataSet*);
88  vtkGetObjectMacro(DataSet,vtkDataSet);
90 
92 
95  vtkSetMacro(OutValue,double);
96  vtkGetMacro(OutValue,double);
98 
100 
103  vtkSetVector3Macro(OutGradient,double);
104  vtkGetVector3Macro(OutGradient,double);
106 
107 protected:
109  ~vtkImplicitDataSet() VTK_OVERRIDE;
110 
111  void ReportReferences(vtkGarbageCollector*) VTK_OVERRIDE;
112 
113  vtkDataSet *DataSet;
114  double OutValue;
115  double OutGradient[3];
116 
117  double *Weights; //used to compute interpolation weights
118  int Size; //keeps track of length of weights array
119 
120 private:
121  vtkImplicitDataSet(const vtkImplicitDataSet&) VTK_DELETE_FUNCTION;
122  void operator=(const vtkImplicitDataSet&) VTK_DELETE_FUNCTION;
123 };
124 
125 #endif
126 
127 
abstract interface for implicit functions
virtual double EvaluateFunction(double x[3])=0
Evaluate function at position x-y-z and return value.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:62
virtual void EvaluateGradient(double x[3], double g[3])=0
Evaluate function gradient at position x-y-z and pass back vector.
vtkTypeUInt64 vtkMTimeType
Definition: vtkType.h:248
Detect and break reference loops.
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkMTimeType GetMTime() override
Overload standard modified time function.
vtkSetMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.
treat a dataset as if it were an implicit function
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.