version 3.3

VRS::Torus Class Reference

Torus. More...

#include <vrs/torus.h>

Inheritance diagram for VRS::Torus:

VRS::Shape VRS::RenderObj VRS::SharedObj VRS::Visitable

List of all members.

Public Member Functions

 Torus (double outerRad=0.75, double innerRad=0.25, const Vector &center=Vector(0, 0, 0), double phimin=0, double phimax=360, double theta=360)
void setCenter (const Vector &)
Vector getCenter () const
 Specifies the center of the torus.
void setOuterRadius (double)
void setInnerRadius (double)
double getOuterRadius () const
double getInnerRadius () const
void setPhi (double minphi, double maxphi)
double getPhiMin () const
double getPhiMax () const
void setTheta (double)
double getTheta () const
virtual Bounds boundingBox () const
 Bounding box of the torus.
 VRS_TYPEINFO (Torus, Shape)
 VRS_SERIALIZABLE (Torus)


Detailed Description

Torus.

Constructor & Destructor Documentation

VRS::Torus::Torus ( double  outerRad = 0.75,
double  innerRad = 0.25,
const Vector center = Vector(0, 0, 0),
double  phimin = 0,
double  phimax = 360,
double  theta = 360 
)

A generalized torus is created by sweping a circle (the ring), not necessarily centered on the origin, by the angle theta around the y axis. Theta is interpreted as for `Disc'. For `phi', see below.


Member Function Documentation

void VRS::Torus::setCenter ( const Vector  ) 

Vector VRS::Torus::getCenter (  )  const [inline]

Specifies the center of the torus.

void VRS::Torus::setOuterRadius ( double   ) 

void VRS::Torus::setInnerRadius ( double   ) 

double VRS::Torus::getOuterRadius (  )  const [inline]

double VRS::Torus::getInnerRadius (  )  const [inline]

The inner radius defines the radius of the ring. The outer radius defines the distance between the center of the torus and the center of the ring.

void VRS::Torus::setPhi ( double  minphi,
double  maxphi 
)

double VRS::Torus::getPhiMin (  )  const [inline]

double VRS::Torus::getPhiMax (  )  const [inline]

Phi min and max specify the ring which is swept around the the y axis. If phi min and phi max are not (0,360), the circle segment will result in an open torus. Phi min must be smaller than phi max.

void VRS::Torus::setTheta ( double   ) 

double VRS::Torus::getTheta (  )  const [inline]

Theta specifies the circle segment used to sweep the circle. By default, theta is set to 360, i.e., a full (and closed) torus will be drawn.

virtual Bounds VRS::Torus::boundingBox (  )  const [virtual]

Bounding box of the torus.

Implements VRS::Shape.

VRS::Torus::VRS_TYPEINFO ( Torus  ,
Shape   
)

VRS::Torus::VRS_SERIALIZABLE ( Torus   ) 


The documentation for this class was generated from the following file:

Generated on Wed May 23 06:00:31 2012 by Doxygen 1.5.6
© 2001-2010 Hasso-Plattner-Institut | Impressum | Contact