VTK
vtkCylinder.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkCylinder.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 =========================================================================*/
35 #ifndef vtkCylinder_h
36 #define vtkCylinder_h
37 
38 #include "vtkCommonDataModelModule.h" // For export macro
39 #include "vtkImplicitFunction.h"
40 
41 class VTKCOMMONDATAMODEL_EXPORT vtkCylinder : public vtkImplicitFunction
42 {
43 public:
45  void PrintSelf(ostream& os, vtkIndent indent) override;
46 
51  static vtkCylinder *New();
52 
54 
58  double EvaluateFunction(double x[3]) override;
60 
64  void EvaluateGradient(double x[3], double g[3]) override;
65 
67 
70  vtkSetMacro(Radius,double);
71  vtkGetMacro(Radius,double);
73 
75 
78  vtkSetVector3Macro(Center,double);
79  vtkGetVector3Macro(Center,double);
81 
83 
88  void SetAxis(double ax, double ay, double az);
89  void SetAxis(double a[3]);
90  vtkGetVector3Macro(Axis,double);
92 
93 protected:
94  vtkCylinder();
95  ~vtkCylinder() override {}
96 
97  double Radius;
98  double Center[3];
99  double Axis[3];
100 
101 private:
102  vtkCylinder(const vtkCylinder&) = delete;
103  void operator=(const vtkCylinder&) = delete;
104 };
105 
106 #endif
vtkCylinder::Radius
double Radius
Definition: vtkCylinder.h:97
vtkObject::New
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
vtkImplicitFunction::EvaluateFunction
virtual double EvaluateFunction(double x[3])=0
Evaluate function at position x-y-z and return value.
vtkCylinder
implicit function for a cylinder
Definition: vtkCylinder.h:41
vtkImplicitFunction
abstract interface for implicit functions
Definition: vtkImplicitFunction.h:60
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkImplicitFunction::EvaluateGradient
virtual void EvaluateGradient(double x[3], double g[3])=0
Evaluate function gradient at position x-y-z and pass back vector.
vtkCylinder::~vtkCylinder
~vtkCylinder() override
Definition: vtkCylinder.h:95
vtkImplicitFunction.h
vtkImplicitFunction::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.