VMTK
vtkvmtkPolyBallLine.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3 Program: VMTK
4 Module: $RCSfile: vtkvmtkPolyBallLine.h,v $
5 Language: C++
6 
7  Copyright (c) Luca Antiga, David Steinman. All rights reserved.
8  See LICENSE file for details.
9 
10  Portions of this code are covered under the VTK copyright.
11  See VTKCopyright.txt or http://www.kitware.com/VTKCopyright.htm
12  for details.
13 
14  This software is distributed WITHOUT ANY WARRANTY; without even
15  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
16  PURPOSE. See the above copyright notices for more information.
17 
18 =========================================================================*/
30 #ifndef __vtkvmtkPolyBallLine_h
31 #define __vtkvmtkPolyBallLine_h
32 
33 #include "vtkImplicitFunction.h"
34 #include "vtkPolyData.h"
35 #include "vtkIdList.h"
36 //#include "vtkvmtkComputationalGeometryWin32Header.h"
37 #include "vtkvmtkWin32Header.h"
38 
39 class VTK_VMTK_COMPUTATIONAL_GEOMETRY_EXPORT vtkvmtkPolyBallLine : public vtkImplicitFunction
40 {
41  public:
42 
43  static vtkvmtkPolyBallLine *New();
44  vtkTypeMacro(vtkvmtkPolyBallLine,vtkImplicitFunction);
45  void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
46 
48 
49  double EvaluateFunction(double x[3]) VTK_OVERRIDE;
50  double EvaluateFunction(double x, double y, double z) VTK_OVERRIDE
51  {return this->vtkImplicitFunction::EvaluateFunction(x, y, z); } ;
53 
55  void EvaluateGradient(double x[3], double n[3]) VTK_OVERRIDE;
56 
58 
59  vtkSetObjectMacro(Input,vtkPolyData);
60  vtkGetObjectMacro(Input,vtkPolyData);
62 
64 
65  vtkSetObjectMacro(InputCellIds,vtkIdList);
66  vtkGetObjectMacro(InputCellIds,vtkIdList);
68 
70 
71  vtkSetMacro(InputCellId,vtkIdType);
72  vtkGetMacro(InputCellId,vtkIdType);
74 
76 
77  vtkSetStringMacro(PolyBallRadiusArrayName);
78  vtkGetStringMacro(PolyBallRadiusArrayName);
80 
82 
83  vtkGetMacro(LastPolyBallCellId,vtkIdType);
84  vtkGetMacro(LastPolyBallCellSubId,vtkIdType);
85  vtkGetMacro(LastPolyBallCellPCoord,double);
86  vtkGetVectorMacro(LastPolyBallCenter,double,3);
87  vtkGetMacro(LastPolyBallCenterRadius,double);
89 
90  vtkSetMacro(UseRadiusInformation,int);
91  vtkGetMacro(UseRadiusInformation,int);
92  vtkBooleanMacro(UseRadiusInformation,int);
93 
94  static double ComplexDot(double x[4], double y[4]);
95 
96  protected:
99 
100  vtkPolyData* Input;
101  vtkIdList* InputCellIds;
102  vtkIdType InputCellId;
103 
108  double LastPolyBallCenter[3];
110 
112 
113  private:
114  vtkvmtkPolyBallLine(const vtkvmtkPolyBallLine&); // Not implemented.
115  void operator=(const vtkvmtkPolyBallLine&); // Not implemented.
116 };
117 
118 #endif
119 
120 
Instance of vtkImplicitFunction which evaluates the minimum sphere function for an envelope created b...
double EvaluateFunction(double x, double y, double z) VTK_OVERRIDE