SoCollisionShapeSphere Class Reference
[libipsa classesCollisionShape classes]

Defines a CollisionShape of type Sphere. This sphere is used for collision handling. More...

#include <SoCollisionShapeSphere.h>

Inheritance diagram for SoCollisionShapeSphere:

Inheritance graph
[legend]
Collaboration diagram for SoCollisionShapeSphere:

Collaboration graph
[legend]

List of all members.

Public Member Functions

virtual SoCollisionShapecopy (SbBool copyConnections) const
 SoCollisionShapeSphere (const SbString &nodeName="")

Static Public Member Functions

static void initClass ()

Public Attributes

SoSFFloat radius

Protected Member Functions

virtual dGeomID cGeom (const SbMatrix &mm)
virtual void updateVisualisationAndOdeProperties ()

Private Member Functions

 SO_KIT_HEADER (SoCollisionShapeSphere)


Detailed Description

Defines a CollisionShape of type Sphere. This sphere is used for collision handling.

Sphere.png

A sphere

Definition at line 32 of file SoCollisionShapeSphere.h.


Constructor & Destructor Documentation

SoCollisionShapeSphere::SoCollisionShapeSphere ( const SbString &  nodeName = ""  ) 

The constructor of SoCollisionShapeSphere. It changes the type of SoCollisionShape::visualisation to SoSphere creates all necessary sensors and calls SoCollisionShapeSphere::setUpConnections().

Parameters:
nodeName name of the node in the Inventor scenegraph

Definition at line 57 of file SoCollisionShapeSphere.cpp.

References radius, and SoCollisionShape::updateOdePropertiesTrigger.


Member Function Documentation

dGeomID SoCollisionShapeSphere::cGeom ( const SbMatrix &  mm  )  [protected, virtual]

Creates a sphere geom object. This method creates a sphere geom using the value from SoCollisionShapeSphere::radius, and returns its ID.

Parameters:
mm the model matrix of the current node
Returns:
dGeomID: The dGeomID of the box geom.

Reimplemented from SoCollisionShape.

Definition at line 112 of file SoCollisionShapeSphere.cpp.

References radius, and SoCollisionShape::space.

SoCollisionShape * SoCollisionShapeSphere::copy ( SbBool  copyConnections  )  const [virtual]

The overwritten copy() method

Parameters:
copyConnections copy connections if true

Reimplemented from SoCollisionShape.

Definition at line 77 of file SoCollisionShapeSphere.cpp.

References SoCollisionShape::setUpConnections().

void SoCollisionShapeSphere::initClass (  )  [static]

Initialises the class and it's type id variables.

Reimplemented from SoCollisionShape.

Definition at line 45 of file SoCollisionShapeSphere.cpp.

SoCollisionShapeSphere::SO_KIT_HEADER ( SoCollisionShapeSphere   )  [private]

void SoCollisionShapeSphere::updateVisualisationAndOdeProperties (  )  [protected, virtual]

This method updates the parameters of the visualisation shape to match those of its parent object. If no visualisation shape is found a default one is created.

Reimplemented from SoCollisionShape.

Definition at line 90 of file SoCollisionShapeSphere.cpp.

References SoCollisionShape::geometry, and radius.


Member Data Documentation


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

Get IPSA - Inventor Physics Simulation API at SourceForge.net. Fast, secure and Free Open Source software downloads
Generated on Sat Mar 10 20:00:20 2012 for IPSA by  doxygen 1.5.8