OpenSim::PathPoint Class Reference

A class implementing a path point. More...

#include <PathPoint.h>

Inheritance diagram for OpenSim::PathPoint:
OpenSim::Object OpenSim::ConditionalPathPoint OpenSim::MovingPathPoint OpenSim::PathWrapPoint

List of all members.

Public Member Functions

 PathPoint ()
 Default constructor.
 PathPoint (const PathPoint &aPoint)
 Copy constructor.
virtual ~PathPoint ()
 Destructor.
virtual Objectcopy () const
 Copy this muscle point and return a pointer to the copy.
PathPointoperator= (const PathPoint &aPoint)
 Assignment operator.
void copyData (const PathPoint &aPoint)
 Copy data members from one PathPoint to another.
virtual void init (const PathPoint &aPoint)
 Initialize a PathPoint with data from another PathPoint.
const SimTK::Vec3 & getLocation () const
SimTK::Vec3 & getLocation ()
const double & getLocationCoord (int aXYZ) const
void setLocationCoord (int aXYZ, double aValue)
void setLocation (const SimTK::State &s, const SimTK::Vec3 &aLocation)
 Set the XYZ location of the point.
void setLocation (const SimTK::State &s, int aCoordIndex, double aLocation)
 Set the X, Y, or Z location of the point.
void setLocation (const SimTK::State &s, double pt[])
void setBody (OpenSim::Body &aBody)
 Set the body that this point is fixed to.
OpenSim::BodygetBody () const
const std::string & getBodyName () const
GeometryPathgetPath () const
virtual void scale (const SimTK::State &s, const SimTK::Vec3 &aScaleFactors)
 Scale the muscle point.
virtual WrapObjectgetWrapObject () const
virtual bool isActive (const SimTK::State &s) const
virtual void setup (const Model &aModel, GeometryPath &aPath)
 Perform some set up functions that happen after the object has been deserialized or copied.
virtual void update (const SimTK::State &s)
virtual void getVelocity (const SimTK::State &s, SimTK::Vec3 &aVelocity)
 Get the velocity of the point in the body's local reference frame.
virtual const VisibleObjectgetDisplayer () const
virtual VisibleObjectupdDisplayer ()
virtual void updateGeometry ()
 Update geometry of the muscle point.
 OPENSIM_DECLARE_DERIVED (PathPoint, Object)

Static Public Member Functions

static PathPointmakePathPointOfType (PathPoint *aPoint, const std::string &aNewTypeName)
static void deletePathPoint (PathPoint *aPoint)

Protected Attributes

const Model_model
PropertyDblVec3 _locationProp
SimTK::Vec3 & _location
PropertyStr _bodyNameProp
std::string & _bodyName
PropertyObj _displayerProp
VisibleObject_displayer
OpenSim::Body_body
GeometryPath_path

Static Protected Attributes

static Geometry_defaultGeometry = AnalyticSphere::createSphere(0.005)
 A temporary kluge until the default mechanism is working.

Detailed Description

A class implementing a path point.

Author:
Peter Loan
Version:
1.0

Constructor & Destructor Documentation

PathPoint::PathPoint (  ) 

Default constructor.

PathPoint::PathPoint ( const PathPoint aPoint  ) 

Copy constructor.

Parameters:
aPoint PathPoint to be copied.
PathPoint::~PathPoint (  )  [virtual]

Destructor.


Member Function Documentation

Object * PathPoint::copy (  )  const [virtual]

Copy this muscle point and return a pointer to the copy.

The copy constructor for this class is used.

Returns:
Pointer to a copy of this PathPoint.

Reimplemented from OpenSim::Object.

Reimplemented in OpenSim::ConditionalPathPoint, OpenSim::MovingPathPoint, and OpenSim::PathWrapPoint.

void PathPoint::copyData ( const PathPoint aPoint  ) 

Copy data members from one PathPoint to another.

Parameters:
aPoint PathPoint to be copied.

Reimplemented in OpenSim::ConditionalPathPoint, OpenSim::MovingPathPoint, and OpenSim::PathWrapPoint.

static void OpenSim::PathPoint::deletePathPoint ( PathPoint aPoint  )  [inline, static]
OpenSim::Body& OpenSim::PathPoint::getBody (  )  const [inline]
const std::string& OpenSim::PathPoint::getBodyName (  )  const [inline]
virtual const VisibleObject* OpenSim::PathPoint::getDisplayer (  )  const [inline, virtual]

Reimplemented from OpenSim::Object.

SimTK::Vec3& OpenSim::PathPoint::getLocation (  )  [inline]
const SimTK::Vec3& OpenSim::PathPoint::getLocation (  )  const [inline]
const double& OpenSim::PathPoint::getLocationCoord ( int  aXYZ  )  const [inline]
GeometryPath* OpenSim::PathPoint::getPath (  )  const [inline]
void PathPoint::getVelocity ( const SimTK::State &  s,
SimTK::Vec3 &  aVelocity 
) [virtual]

Get the velocity of the point in the body's local reference frame.

Parameters:
aVelocity The velocity.

Reimplemented in OpenSim::MovingPathPoint.

virtual WrapObject* OpenSim::PathPoint::getWrapObject (  )  const [inline, virtual]

Reimplemented in OpenSim::PathWrapPoint.

void PathPoint::init ( const PathPoint aPoint  )  [virtual]

Initialize a PathPoint with data from another PathPoint.

Parameters:
aPoint PathPoint to be copied.
virtual bool OpenSim::PathPoint::isActive ( const SimTK::State &  s  )  const [inline, virtual]
static PathPoint* OpenSim::PathPoint::makePathPointOfType ( PathPoint aPoint,
const std::string &  aNewTypeName 
) [static]
OpenSim::PathPoint::OPENSIM_DECLARE_DERIVED ( PathPoint  ,
Object   
)
PathPoint & PathPoint::operator= ( const PathPoint aPoint  ) 

Assignment operator.

Returns:
Reference to this object.

Reimplemented from OpenSim::Object.

Reimplemented in OpenSim::ConditionalPathPoint, OpenSim::MovingPathPoint, and OpenSim::PathWrapPoint.

void PathPoint::scale ( const SimTK::State &  s,
const SimTK::Vec3 &  aScaleFactors 
) [virtual]

Scale the muscle point.

Parameters:
aScaleFactors the XYZ scale factors to scale the point by.

Reimplemented in OpenSim::MovingPathPoint.

void PathPoint::setBody ( OpenSim::Body aBody  ) 

Set the body that this point is fixed to.

Parameters:
aBody Reference to the body.
void OpenSim::PathPoint::setLocation ( const SimTK::State &  s,
double  pt[] 
) [inline]
void PathPoint::setLocation ( const SimTK::State &  s,
int  aCoordIndex,
double  aLocation 
)

Set the X, Y, or Z location of the point.

Parameters:
aCoordIndex The coordinate to change (0=X, 1=Y, 2=Z).
aLocation The X, Y, or Z coordinate.
void PathPoint::setLocation ( const SimTK::State &  s,
const SimTK::Vec3 &  aLocation 
)

Set the XYZ location of the point.

Parameters:
aLocation The XYZ coordinates.
void OpenSim::PathPoint::setLocationCoord ( int  aXYZ,
double  aValue 
) [inline]
void PathPoint::setup ( const Model aModel,
GeometryPath aPath 
) [virtual]

Perform some set up functions that happen after the object has been deserialized or copied.

Parameters:
aModel model containing this PathPoint.

Reimplemented in OpenSim::ConditionalPathPoint, OpenSim::MovingPathPoint, and OpenSim::PathWrapPoint.

virtual void OpenSim::PathPoint::update ( const SimTK::State &  s  )  [inline, virtual]

Reimplemented in OpenSim::MovingPathPoint.

void PathPoint::updateGeometry (  )  [virtual]

Update geometry of the muscle point.

virtual VisibleObject* OpenSim::PathPoint::updDisplayer (  )  [inline, virtual]

Reimplemented from OpenSim::Object.


Member Data Documentation

std::string& OpenSim::PathPoint::_bodyName [protected]
Geometry * PathPoint::_defaultGeometry = AnalyticSphere::createSphere(0.005) [static, protected]

A temporary kluge until the default mechanism is working.

SimTK::Vec3& OpenSim::PathPoint::_location [protected]
const Model* OpenSim::PathPoint::_model [protected]

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

Generated on Wed Dec 16 15:03:46 2009 for OpenSim by  doxygen 1.6.1