VTK
vtkQuadric.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkQuadric.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 =========================================================================*/
30 #ifndef vtkQuadric_h
31 #define vtkQuadric_h
32 
33 #include "vtkCommonDataModelModule.h" // For export macro
34 #include "vtkImplicitFunction.h"
35 
36 class VTKCOMMONDATAMODEL_EXPORT vtkQuadric : public vtkImplicitFunction
37 {
38 public:
40  void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
41 
45  static vtkQuadric *New();
46 
48 
51  double EvaluateFunction(double x[3]) VTK_OVERRIDE;
52  double EvaluateFunction(double x, double y, double z)
53  {return this->vtkImplicitFunction::EvaluateFunction(x, y, z); } ;
55 
59  void EvaluateGradient(double x[3], double g[3]) VTK_OVERRIDE;
60 
62 
65  void SetCoefficients(double a[10]);
66  void SetCoefficients(double a0, double a1, double a2, double a3, double a4,
67  double a5, double a6, double a7, double a8, double a9);
68  vtkGetVectorMacro(Coefficients,double,10);
70 
71 protected:
72  vtkQuadric();
73  ~vtkQuadric() VTK_OVERRIDE {}
74 
75  double Coefficients[10];
76 
77 private:
78  vtkQuadric(const vtkQuadric&) VTK_DELETE_FUNCTION;
79  void operator=(const vtkQuadric&) VTK_DELETE_FUNCTION;
80 };
81 
82 #endif
83 
84 
abstract interface for implicit functions
virtual double EvaluateFunction(double x[3])=0
Evaluate function at position x-y-z and return value.
double EvaluateFunction(double x, double y, double z)
Evaluate quadric equation.
Definition: vtkQuadric.h:52
~vtkQuadric() override
Definition: vtkQuadric.h:73
virtual void EvaluateGradient(double x[3], double g[3])=0
Evaluate function gradient at position x-y-z and pass back vector.
a simple class to control print indentation
Definition: vtkIndent.h:39
evaluate implicit quadric function
Definition: vtkQuadric.h:36
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.