sparkle::Group Class Reference
[Sparkle Library]
Basic grouping of shapes.
More...
#include <group.h>
Inherits sparkle::SceneObject.
Collaboration diagram for sparkle::Group:
[legend]List of all members.
Detailed Description
Basic grouping of shapes.
A simple logical grouping of shapes to easily create more complex shapes. The shapes will be rigidly fixed together.
It is optional to assign a shape to a group.
Constructor & Destructor Documentation
|
|
Create a group with no members |
Member Function Documentation
| int Group::addShape |
( |
Shape * |
newShape |
) |
|
|
|
|
Add a new shape to the group - Parameters:
-
| newShape | The new shape to be added |
- Returns:
- The number of shapes in the group
|
| int Group::removeShape |
( |
Shape * |
shapeToRemove |
) |
|
|
|
|
Removes the specified shape from the group - Parameters:
-
| shapeToRemove | The new shape to be removed |
- Returns:
- The number of shapes in the group
|
| void sparkle::Group::setName |
( |
std::string |
newName |
) |
[inline] |
|
|
|
Set the name of the group - Parameters:
-
|
| int sparkle::Group::numOfShapes |
( |
|
) |
const [inline] |
|
|
|
- Returns:
- The number of shapes in the group
|
| Shape* sparkle::Group::shapeAt |
( |
int |
index |
) |
[inline] |
|
|
|
- Parameters:
-
| index | The index of the shape within the group |
- Returns:
- A pointer to the shape at
index
|
| std::string sparkle::Group::name |
( |
|
) |
const [inline] |
|
|
|
- Returns:
- The name of the group
|
| double Group::momentOfInertia |
( |
|
) |
|
|
|
|
Calculates the moment of inertia for the whole group using the parallel-axis theorem - Returns:
- The moment of inertia of the whole group
|
Member Data Documentation
|
|
List of shapes in the group |
Hosted by
Generated on Sat Sep 16 01:51:09 2006 for Sparkle by Doxygen 1.4.6.