VTK
vtkSphereSource.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkSphereSource.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 =========================================================================*/
37 #ifndef vtkSphereSource_h
38 #define vtkSphereSource_h
39 
40 #include "vtkFiltersSourcesModule.h" // For export macro
41 #include "vtkPolyDataAlgorithm.h"
42 
43 #define VTK_MAX_SPHERE_RESOLUTION 1024
44 
46 {
47 public:
49  void PrintSelf(ostream& os, vtkIndent indent);
50 
54  static vtkSphereSource *New();
55 
57 
58  vtkSetClampMacro(Radius,double,0.0,VTK_DOUBLE_MAX);
59  vtkGetMacro(Radius,double);
61 
63 
64  vtkSetVector3Macro(Center,double);
65  vtkGetVectorMacro(Center,double,3);
67 
69 
71  vtkSetClampMacro(ThetaResolution,int,3,VTK_MAX_SPHERE_RESOLUTION);
72  vtkGetMacro(ThetaResolution,int);
74 
76 
78  vtkSetClampMacro(PhiResolution,int,3,VTK_MAX_SPHERE_RESOLUTION);
79  vtkGetMacro(PhiResolution,int);
81 
83 
84  vtkSetClampMacro(StartTheta,double,0.0,360.0);
85  vtkGetMacro(StartTheta,double);
87 
89 
90  vtkSetClampMacro(EndTheta,double,0.0,360.0);
91  vtkGetMacro(EndTheta,double);
93 
95 
97  vtkSetClampMacro(StartPhi,double,0.0,360.0);
98  vtkGetMacro(StartPhi,double);
100 
102 
103  vtkSetClampMacro(EndPhi,double,0.0,360.0);
104  vtkGetMacro(EndPhi,double);
106 
108 
114  vtkSetMacro(LatLongTessellation,int);
115  vtkGetMacro(LatLongTessellation,int);
116  vtkBooleanMacro(LatLongTessellation,int);
118 
120 
124  vtkSetMacro(OutputPointsPrecision,int);
125  vtkGetMacro(OutputPointsPrecision,int);
127 
128 protected:
129  vtkSphereSource(int res=8);
131 
134 
135  double Radius;
136  double Center[3];
139  double StartTheta;
140  double EndTheta;
141  double StartPhi;
142  double EndPhi;
145 
146 private:
147  vtkSphereSource(const vtkSphereSource&); // Not implemented.
148  void operator=(const vtkSphereSource&); // Not implemented.
149 };
150 
151 #endif
#define VTK_DOUBLE_MAX
Definition: vtkType.h:142
Store vtkAlgorithm input/output information.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
static vtkPolyDataAlgorithm * New()
void PrintSelf(ostream &os, vtkIndent indent)
create a polygonal sphere centered at the origin
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:38
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
#define VTKFILTERSSOURCES_EXPORT
Store zero or more vtkInformation instances.
#define VTK_MAX_SPHERE_RESOLUTION