A class implementing a cylinder for muscle wrapping. More...
#include <WrapCylinder.h>
Public Member Functions | |
WrapCylinder () | |
Default constructor. | |
WrapCylinder (const WrapCylinder &aWrapCylinder) | |
Copy constructor. | |
virtual | ~WrapCylinder () |
Destructor. | |
virtual Object * | copy () const |
Copy this WrapCylinder and return a pointer to the copy. | |
WrapCylinder & | operator= (const WrapCylinder &aWrapCylinder) |
Assignment operator. | |
void | copyData (const WrapCylinder &aWrapCylinder) |
Copy data members from one WrapCylinder to another. | |
double | getRadius () const |
void | setRadius (double aRadius) |
double | getLength () const |
void | setLength (double aLength) |
virtual const char * | getWrapTypeName () const |
Get the name of the type of wrap object ("cylinder" in this case). | |
virtual std::string | getDimensionsString () const |
Get a string holding the dimensions definition that SIMM would use to describe this object. | |
virtual void | scale (const SimTK::Vec3 &aScaleFactors) |
Scale the cylinder's dimensions. | |
virtual void | setup (Model &aModel, OpenSim::Body &aBody) |
Perform some set up functions that happen after the object has been deserialized or copied. | |
virtual int | wrapLine (const SimTK::State &s, SimTK::Vec3 &aPoint1, SimTK::Vec3 &aPoint2, const PathWrap &aPathWrap, WrapResult &aWrapResult, bool &aFlag) const |
Calculate the wrapping of one line segment over the cylinder. | |
Protected Member Functions | |
void | setupProperties () |
Connect properties to local pointers. |
A class implementing a cylinder for muscle wrapping.
WrapCylinder::WrapCylinder | ( | ) |
Default constructor.
WrapCylinder::WrapCylinder | ( | const WrapCylinder & | aWrapCylinder | ) |
Copy constructor.
aWrapCylinder | WrapCylinder to be copied. |
WrapCylinder::~WrapCylinder | ( | ) | [virtual] |
Destructor.
Object * WrapCylinder::copy | ( | ) | const [virtual] |
Copy this WrapCylinder and return a pointer to the copy.
The copy constructor for this class is used.
Implements OpenSim::WrapObject.
void WrapCylinder::copyData | ( | const WrapCylinder & | aWrapCylinder | ) |
Copy data members from one WrapCylinder to another.
aWrapCylinder | WrapCylinder to be copied. |
Reimplemented from OpenSim::WrapObject.
string WrapCylinder::getDimensionsString | ( | ) | const [virtual] |
Get a string holding the dimensions definition that SIMM would use to describe this object.
This is a rather ugly convenience function for outputting SIMM joint files.
Reimplemented from OpenSim::WrapObject.
double OpenSim::WrapCylinder::getLength | ( | ) | const [inline] |
double OpenSim::WrapCylinder::getRadius | ( | ) | const [inline] |
const char * WrapCylinder::getWrapTypeName | ( | ) | const [virtual] |
Get the name of the type of wrap object ("cylinder" in this case).
Implements OpenSim::WrapObject.
WrapCylinder & WrapCylinder::operator= | ( | const WrapCylinder & | aWrapCylinder | ) |
void WrapCylinder::scale | ( | const SimTK::Vec3 & | aScaleFactors | ) | [virtual] |
Scale the cylinder's dimensions.
The base class scales the origin of the cylinder in the body's reference frame.
aScaleFactors | The XYZ scale factors. |
Reimplemented from OpenSim::WrapObject.
void OpenSim::WrapCylinder::setLength | ( | double | aLength | ) | [inline] |
void OpenSim::WrapCylinder::setRadius | ( | double | aRadius | ) | [inline] |
void WrapCylinder::setup | ( | Model & | aModel, | |
OpenSim::Body & | aBody | |||
) | [virtual] |
Perform some set up functions that happen after the object has been deserialized or copied.
aModel | pointer to OpenSim model. |
Reimplemented from OpenSim::WrapObject.
void WrapCylinder::setupProperties | ( | void | ) | [protected] |
Connect properties to local pointers.
Reimplemented from OpenSim::WrapObject.
int WrapCylinder::wrapLine | ( | const SimTK::State & | s, | |
SimTK::Vec3 & | aPoint1, | |||
SimTK::Vec3 & | aPoint2, | |||
const PathWrap & | aPathWrap, | |||
WrapResult & | aWrapResult, | |||
bool & | aFlag | |||
) | const [virtual] |
Calculate the wrapping of one line segment over the cylinder.
aPoint1 | One end of the line segment | |
aPoint2 | The other end of the line segment | |
aPathWrap | An object holding the parameters for this line/cylinder pairing | |
aWrapResult | The result of the wrapping (tangent points, etc.) | |
aFlag | A flag for indicating errors, etc. |
Implements OpenSim::WrapObject.