Home   Information   Classes   Download   Usage   Mail List   Requirements   Links   FAQ   Tutorial


stk::Sphere Class Reference

STK sphere class. More...

#include <Sphere.h>

Inheritance diagram for stk::Sphere:
stk::Stk

List of all members.

Public Member Functions

 Sphere (StkFloat radius=1.0)
 Constructor taking an initial radius value.
void setPosition (StkFloat x, StkFloat y, StkFloat z)
 Set the 3D center position of the sphere.
void setVelocity (StkFloat x, StkFloat y, StkFloat z)
 Set the 3D velocity of the sphere.
void setRadius (StkFloat radius)
 Set the radius of the sphere.
void setMass (StkFloat mass)
 Set the mass of the sphere.
Vector3DgetPosition (void)
 Get the current position of the sphere as a 3D vector.
Vector3DgetRelativePosition (Vector3D *position)
 Get the relative position of the given point to the sphere as a 3D vector.
StkFloat getVelocity (Vector3D *velocity)
 Set the velcoity of the sphere as a 3D vector.
StkFloat isInside (Vector3D *position)
 Returns the distance from the sphere boundary to the given position (< 0 if inside).
StkFloat getRadius (void)
 Get the current sphere radius.
StkFloat getMass (void)
 Get the current sphere mass.
void addVelocity (StkFloat x, StkFloat y, StkFloat z)
 Increase the current sphere velocity by the given 3D components.
void tick (StkFloat timeIncrement)
 Move the sphere for the given time increment.

Detailed Description

STK sphere class.

This class implements a spherical ball with radius, mass, position, and velocity parameters.

by Perry R. Cook, 1995 - 2010.


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

The Synthesis ToolKit in C++ (STK)
©1995-2010 Perry R. Cook and Gary P. Scavone. All Rights Reserved.