VTK  9.0.1
vtkTexturedSphereSource.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkTexturedSphereSource.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 =========================================================================*/
26 #ifndef vtkTexturedSphereSource_h
27 #define vtkTexturedSphereSource_h
28 
29 #include "vtkFiltersSourcesModule.h" // For export macro
30 #include "vtkPolyDataAlgorithm.h"
31 
32 #define VTK_MAX_SPHERE_RESOLUTION 1024
33 
34 class VTKFILTERSSOURCES_EXPORT vtkTexturedSphereSource : public vtkPolyDataAlgorithm
35 {
36 public:
38  void PrintSelf(ostream& os, vtkIndent indent) override;
39 
45 
47 
50  vtkSetClampMacro(Radius, double, 0.0, VTK_DOUBLE_MAX);
51  vtkGetMacro(Radius, double);
53 
55 
58  vtkSetClampMacro(ThetaResolution, int, 4, VTK_MAX_SPHERE_RESOLUTION);
59  vtkGetMacro(ThetaResolution, int);
61 
63 
66  vtkSetClampMacro(PhiResolution, int, 4, VTK_MAX_SPHERE_RESOLUTION);
67  vtkGetMacro(PhiResolution, int);
69 
71 
74  vtkSetClampMacro(Theta, double, 0.0, 360.0);
75  vtkGetMacro(Theta, double);
77 
79 
82  vtkSetClampMacro(Phi, double, 0.0, 180.0);
83  vtkGetMacro(Phi, double);
85 
87 
92  vtkSetMacro(OutputPointsPrecision, int);
93  vtkGetMacro(OutputPointsPrecision, int);
95 
96 protected:
99 
101  double Radius;
102  double Theta;
103  double Phi;
107 
108 private:
110  void operator=(const vtkTexturedSphereSource&) = delete;
111 };
112 
113 #endif
a simple class to control print indentation
Definition: vtkIndent.h:34
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that produce only polydata as output.
create a sphere centered at the origin
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkTexturedSphereSource(int res=8)
static vtkTexturedSphereSource * New()
Construct sphere with radius=0.5 and default resolution 8 in both Phi and Theta directions.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
#define VTK_MAX_SPHERE_RESOLUTION
#define VTK_DOUBLE_MAX
Definition: vtkType.h:165