VTK
vtkImplicitPolyDataDistance.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImplicitPolyDataDistance.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 =========================================================================*/
41 #ifndef vtkImplicitPolyDataDistance_h
42 #define vtkImplicitPolyDataDistance_h
43 
44 #include "vtkFiltersCoreModule.h" // For export macro
45 #include "vtkImplicitFunction.h"
46 
47 class vtkCellLocator;
48 class vtkPolyData;
49 
51 {
52 public:
55  void PrintSelf(ostream& os, vtkIndent indent);
56 
58  unsigned long GetMTime();
59 
61  double EvaluateFunction(double x[3]);
62 
64  void EvaluateGradient(double x[3], double g[3]);
65 
68  double EvaluateFunctionAndGetClosestPoint (double x[3], double closestPoint[3]);
69 
74  void SetInput(vtkPolyData *input);
75 
77 
78  vtkSetMacro(NoValue, double);
79  vtkGetMacro(NoValue, double);
81 
83 
85  vtkSetVector3Macro(NoGradient, double);
86  vtkGetVector3Macro(NoGradient, double);
88 
90 
91  vtkSetVector3Macro(NoClosestPoint, double);
92  vtkGetVector3Macro(NoClosestPoint, double);
94 
96 
97  vtkGetMacro(Tolerance, double);
98  vtkSetMacro(Tolerance, double);
100 
101 protected:
104 
106  void CreateDefaultLocator(void);
107 
108  double SharedEvaluate(double x[3], double g[3], double p[3]);
109 
110  double NoGradient[3];
111  double NoClosestPoint[3];
112  double NoValue;
113  double Tolerance;
114 
117 
118 private:
119  vtkImplicitPolyDataDistance(const vtkImplicitPolyDataDistance&); // Not implemented.
120  void operator=(const vtkImplicitPolyDataDistance&); // Not implemented.
121 };
122 
123 #endif
abstract interface for implicit functions
virtual double EvaluateFunction(double x[3])=0
#define VTKFILTERSCORE_EXPORT
unsigned long GetMTime()
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:84
virtual void EvaluateGradient(double x[3], double g[3])=0
octree-based spatial search object to quickly locate cells
a simple class to control print indentation
Definition: vtkIndent.h:38
void PrintSelf(ostream &os, vtkIndent indent)
static vtkObject * New()