NAME
vtkSphereSource - create a sphere centered at the origin
SYNOPSIS
#include "/opt/vtk-c++/graphics/vtkSphereSource.h"
class VTK_EXPORT vtkSphereSource : public vtkPolyDataSource
vtkSphereSource(int res=8);
static vtkSphereSource *New() {return new vtkSphereSource;};
const char *GetClassName() {return "vtkSphereSource";};
void PrintSelf(ostream& os, vtkIndent indent);
void SetRadius(float);
float GetRadius();
void SetCenter(float, float, float);
void SetCenter(float *);
float *GetCenter();
void GetCenter(float data[3]);
void SetThetaResolution(int);
int GetThetaResolution();
void SetPhiResolution(int);
int GetPhiResolution();
void SetTheta(float);
float GetTheta();
void SetPhi(float);
float GetPhi();
DESCRIPTION
vtkSphereSource creates a polygonal sphere of specified radius centered at the origin. The resolution (polygonal discretization) in both the latitude (phi) and longitude (theta) directions can be specified. It also is possible to create partial spheres by specifying maximum phi and theta angles.
DEFINED MACROS
VTK_MAX_SPHERE_RESOLUTION 1024
SUMMARY
void SetRadius(float)
Set radius of sphere. Default is .5.
void SetCenter(float, float, float)
void SetCenter(float *)
Set the center of the sphere. Default is 0,0,0.
void SetThetaResolution(int)
Set the number of points in the longitude direction.
void SetPhiResolution(int)
Set the number of points in the latitude direction.
void SetTheta(float)
Set the maximum longitude angle.
void SetPhi(float)
Set the maximum latitude angle (0 is at north pole).
vtkSphereSource(int res)
Construct sphere with radius=0.5 and default resolution 8 in both Phi and Theta directions.