Documentation for vtkSuperquadricSource

vtkSuperquadricSource - create a polygonal superquadric centered

Super Class: vtkPolyDataSource

Description:

vtkSuperquadricSource creates a superquadric (represented by polygons) of specified size centered at the origin. The resolution (polygonal discretization) in both the latitude (phi) and longitude (theta) directions can be specified. Roundness parameters (PhiRoundness and ThetaRoundness) control the shape of the superquadric. The Toroidal boolean controls whether a toroidal superquadric is produced. If so, the Thickness parameter controls the thickness of the toroid: 0 is the thinnest allowable toroid, and 1 has a minimum sized hole. The Scale parameters allow the superquadric to be scaled in x, y, and z (normal vectors are correctly generated in any case). The Size parameter controls size of the superquadric. This code is based on "Rigid physically based superquadrics", A. H. Barr, in "Graphics Gems III", David Kirk, ed., Academic Press, 1992.

 

Caveats:

Resolution means the number of latitude or longitude lines for a complete superquadric. The resolution parameters are rounded to the nearest 4 in phi and 8 in theta. Texture coordinates are not equally distributed around all superquadrics. The Size and Thickness parameters control coefficients of superquadric generation, and may do not exactly describe the size of the superquadric.

 

Methods:

void vtkSuperquadricSource (int )
static vtkSuperquadricSource *New ()
const char *GetClassName ()
void PrintSelf (unknown & ,vtkIndent )
void SetCenter (float ,float ,float )
void SetCenter (float *)
float *GetCenter ()
void SetScale (float ,float ,float )
void SetScale (float *)
float *GetScale ()
int GetThetaResolution ()
void SetThetaResolution (int )
int GetPhiResolution ()
void SetPhiResolution (int )
float GetThickness ()
void SetThickness (float )
float GetPhiRoundness ()
void SetPhiRoundness (float )
float GetThetaRoundness ()
void SetThetaRoundness (float )
void SetSize (float )
float GetSize ()
void ToroidalOn ()
void ToroidalOff ()
int GetToroidal ()
void SetToroidal (int )
void Execute ()

 

Detailed Method Descriptions:

Create a default superquadric with a radius of 0.5, non-toroidal, spherical, and centered at the origin.

void vtkSuperquadricSource (int )
static vtkSuperquadricSource *New ()
const char *GetClassName ()
void PrintSelf (unknown & ,vtkIndent )

Set the center of the superquadric. Default is 0,0,0.

void SetCenter (float ,float ,float )
void SetCenter (float *)
float *GetCenter ()

Set the scale factors of the superquadric. Default is 1,1,1.

void SetScale (float ,float ,float )
void SetScale (float *)
float *GetScale ()

Set the number of points in the longitude direction.

int GetThetaResolution ()
void SetThetaResolution (int )

Set the number of points in the latitude direction.

int GetPhiResolution ()
void SetPhiResolution (int )

Set/Get Superquadric ring thickness (toriods only). Changing thickness maintains the outside diameter of the toroid.

float GetThickness ()
void SetThickness (float )

Set/Get Superquadric north/south roundness. Values range from 0 (rectanglar) to 1 (circular) to higher orders.

float GetPhiRoundness ()
void SetPhiRoundness (float )

Set/Get Superquadric east/west roundness. Values range from 0 (rectanglar) to 1 (circular) to higher orders.

float GetThetaRoundness ()
void SetThetaRoundness (float )

Set/Get Superquadric isotropic size.

void SetSize (float )
float GetSize ()

Set/Get whether or not the superquadric is toroidal (1) or episoidal (0).

void ToroidalOn ()
void ToroidalOff ()
int GetToroidal ()
void SetToroidal (int )