VTK  9.2.6
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 =========================================================================*/
27 #ifndef vtkQuadric_h
28 #define vtkQuadric_h
29 
30 #include "vtkCommonDataModelModule.h" // For export macro
31 #include "vtkImplicitFunction.h"
32 
33 class VTKCOMMONDATAMODEL_EXPORT vtkQuadric : public vtkImplicitFunction
34 {
35 public:
37  void PrintSelf(ostream& os, vtkIndent indent) override;
38 
42  static vtkQuadric* New();
43 
45 
49  double EvaluateFunction(double x[3]) override;
51 
55  void EvaluateGradient(double x[3], double g[3]) override;
56 
58 
61  void SetCoefficients(double a[10]);
62  void SetCoefficients(double a0, double a1, double a2, double a3, double a4, double a5, double a6,
63  double a7, double a8, double a9);
64  vtkGetVectorMacro(Coefficients, double, 10);
66 
67 protected:
68  vtkQuadric();
69  ~vtkQuadric() override = default;
70 
71  double Coefficients[10];
72 
73 private:
74  vtkQuadric(const vtkQuadric&) = delete;
75  void operator=(const vtkQuadric&) = delete;
76 };
77 
78 #endif
abstract interface for implicit functions
virtual double EvaluateFunction(double x[3])=0
Evaluate function at position x-y-z and return value.
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:33
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.