PhyJoint class. More...

Inheritance diagram for PhyJoint:

List of all members.

Public Member Functions

 PhyJoint (PhyObject *parent, PhyObject *child)
 Constructor.
virtual ~PhyJoint ()
 Destructor.
virtual wVector centre () const =0
 Return the centre of this joint in world coordinate.
virtual const PhyObjectchild () const
 Return the child object attached to this joint (see Newton Documentation) (const version)
virtual PhyObjectchild ()
 Return the child object attached to this joint (see Newton Documentation)
virtual QVector< PhyDOF * > dofs ()
 Return descriptions of DOF.
void enable (bool b)
 enable/disable the joint
bool isEnabled () const
 Return true if the joint is enabled.
virtual unsigned int numDofs () const
 Return the number of DOF constrained by this joint.
virtual PhyObjectparent ()
 Return the parent object; (NULL means an object attached to static world; see Netwon Documentation)
virtual const PhyObjectparent () const
 Return the parent object; (NULL means an object attached to static world; see Netwon Documentation) (const version)
virtual void postUpdate ()
 postUpdate the PhyJoint this method is called at each step of the world just after the physic update
virtual void preUpdate ()
 preUpdate the PhyJoint this method is called at each step of the world just before the physic update
virtual void updateJointInfo ()=0
 Update the Joint informations (each PhyDOF will be updated)
Worldworld ()
 Return the World.
const Worldworld () const
 Return the World (const version)

Protected Member Functions

virtual void updateJoint (real timestep)=0

Protected Attributes

PhyObjectPrivate * childpriv
PhyObjectchildv
 child object
QVector< PhyDOF * > dofsv
 vector of DOF's joint
int dofv
 number of DOF
bool enabled
 true if is enabled, false otherwise
PhyObjectPrivate * parentpriv
PhyObjectparentv
 parent object
PhyJointPrivate * priv
 Engine encapsulation.
WorldPrivate * worldpriv
Worldworldv
 world

Friends

class PhyJointPrivate

Detailed Description

PhyJoint class.

\

Motivation
Common interface among Joints.
Description
This joint doesn't add constraints... so, it's a zero-DOF joint :-)
Warnings
Warnings

Definition at line 336 of file phyjoint.h.


Constructor & Destructor Documentation

PhyJoint ( PhyObject parent,
PhyObject child 
)

Constructor.

Parameters:
parentis the parent object. The local frame is translated toward centre for create the complete local coordinate frame of this joint
childis the child object

Definition at line 30 of file phyjoint.cpp.

References PhyJoint::child(), PhyJoint::childv, PhyJoint::enabled, PhyJoint::parent(), PhyJoint::parentv, PhyObject::priv, PhyJoint::priv, WObject::world(), and PhyJoint::worldv.

~PhyJoint ( ) [virtual]

Destructor.

Definition at line 52 of file phyjoint.cpp.

References PhyJoint::dofsv, PhyJoint::priv, and PhyJoint::worldv.


Member Function Documentation

virtual wVector centre ( ) const [pure virtual]

Return the centre of this joint in world coordinate.

Implemented in PhyBallAndSocket, PhyFixed, PhyHinge, and PhySuspension.

virtual PhyObject* child ( ) [inline, virtual]

Return the child object attached to this joint (see Newton Documentation)

Definition at line 348 of file phyjoint.h.

Referenced by PhyJoint::PhyJoint(), PhyUniversal::updateJointInfo(), PhySuspension::updateJointInfo(), PhyHinge::updateJointInfo(), PhyFixed::updateJointInfo(), and PhyBallAndSocket::updateJointInfo().

virtual const PhyObject* child ( ) const [inline, virtual]

Return the child object attached to this joint (see Newton Documentation) (const version)

Definition at line 352 of file phyjoint.h.

virtual QVector<PhyDOF*> dofs ( ) [inline, virtual]

Return descriptions of DOF.

Definition at line 368 of file phyjoint.h.

Referenced by PhyObjectsGroup::addJointDOF(), PhyMarXbot::PhyMarXbot(), and PhyObjectsGroup::setDOFPosition().

void enable ( bool  b)

enable/disable the joint

Definition at line 63 of file phyjoint.cpp.

References PhyJoint::enabled.

bool isEnabled ( ) const [inline]

Return true if the joint is enabled.

Definition at line 374 of file phyjoint.h.

virtual unsigned int numDofs ( ) const [inline, virtual]

Return the number of DOF constrained by this joint.

Definition at line 364 of file phyjoint.h.

Referenced by PhyObjectsGroup::addJointDOF(), and PhyiCub::PhyiCub().

virtual const PhyObject* parent ( ) const [inline, virtual]

Return the parent object; (NULL means an object attached to static world; see Netwon Documentation) (const version)

Definition at line 360 of file phyjoint.h.

virtual PhyObject* parent ( ) [inline, virtual]
virtual void postUpdate ( ) [inline, virtual]

postUpdate the PhyJoint this method is called at each step of the world just after the physic update

Definition at line 405 of file phyjoint.h.

virtual void preUpdate ( ) [inline, virtual]

preUpdate the PhyJoint this method is called at each step of the world just before the physic update

Definition at line 398 of file phyjoint.h.

virtual void updateJointInfo ( ) [pure virtual]

Update the Joint informations (each PhyDOF will be updated)

Implemented in PhyBallAndSocket, PhyFixed, PhyHinge, PhySuspension, and PhyUniversal.

Referenced by PhyMarXbot::changedMatrix(), PhyiCub::changedMatrix(), PhyiCub::configurePosture(), and PhyMarXbot::PhyMarXbot().

const World* world ( ) const [inline]

Return the World (const version)

Definition at line 390 of file phyjoint.h.

World* world ( ) [inline]

Member Data Documentation

PhyObject* childv [protected]

child object

Definition at line 419 of file phyjoint.h.

Referenced by PhyJoint::PhyJoint().

bool enabled [protected]

true if is enabled, false otherwise

Definition at line 415 of file phyjoint.h.

Referenced by PhyJoint::enable(), PhyJoint::PhyJoint(), PhySuspension::updateJointInfo(), and PhyHinge::updateJointInfo().

PhyObject* parentv [protected]

parent object

Definition at line 417 of file phyjoint.h.

Referenced by PhyJoint::PhyJoint().

World* worldv [protected]

world

Definition at line 421 of file phyjoint.h.

Referenced by PhyJoint::PhyJoint(), and PhyJoint::~PhyJoint().


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