MathEngine
Home Page       Structures       File List       Functions and Macros      

MdtLinear2.h File Reference

MdtLinear2 API functions. More...

#include "MePrecision.h"
#include "MdtTypes.h"

Functions

MdtLinear2ID MdtLinear2Create (const MdtWorldID w, const MdtBodyID b1, const MdtBodyID b2)
 Creates a new linear 2 joint with default parameters. More...

void MdtLinear2Reset (const MdtLinear2ID j)
 Sets a linear2 joint to its default values. More...

void MdtLinear2Destroy (const MdtLinear2ID j)
 Destroys a linear 2 joint. More...

void MdtLinear2Log (const MdtLinear2ID j)
 Debug function - output constraint using MeMessage. More...

MdtConstraintID MdtLinear2QuaConstraint (const MdtLinear2ID j)
 Gets an MdtConstraintID from a specific constraint for performing functions common to all constraints. More...

void MdtLinear2GetPosition (const MdtLinear2ID j, MeVector3 position)
 The linear 2 joint's position vector is returned in v. More...

void MdtLinear2GetDirection (const MdtLinear2ID j, MeVector3 direction)
 The linear 2 joint's direction vector is returned in v. More...

void MdtLinear2SetPosition (const MdtLinear2ID j, const MeReal x, const MeReal y, const MeReal z)
 Sets the joint position in world coordinates. More...

void MdtLinear2SetDirection (const MdtLinear2ID j, const MeReal x, const MeReal y, const MeReal z)
 Sets the joint direction in world coordinates. More...


Detailed Description

MdtLinear2 API functions.

The joint is constrained to lie on a line fixed by its initial position and a direction vector fixed in the reference frame of the secondary body, or fixed in the inertial frame if there is no secondary body.


Define Documentation

#define MdtLinear2Disable( j )

Initializer:

\
                            MdtConstraintDisable(MdtLinear2QuaConstraint(j))

#define MdtLinear2Enable( j )

Initializer:

\
                            MdtConstraintEnable(MdtLinear2QuaConstraint(j))

#define MdtLinear2GetBody( j, bodyindex )

Initializer:

\
                            MdtConstraintGetBody(MdtLinear2QuaConstraint(j), bodyindex)

#define MdtLinear2GetForce( j, bodyindex, f )

Initializer:

\
                            MdtConstraintGetForce(MdtLinear2QuaConstraint(j), bodyindex, f)

#define MdtLinear2GetTorque( j, bodyindex, t )

Initializer:

\
                            MdtConstraintGetTorque(MdtLinear2QuaConstraint(j), bodyindex, t)

#define MdtLinear2GetUserData( j )

Initializer:

\
                            MdtConstraintGetUserData(MdtLinear2QuaConstraint(j))

#define MdtLinear2GetWorld( j )

Initializer:

\
                            MdtConstraintGetWorld(MdtLinear2QuaConstraint(j))

#define MdtLinear2IsEnabled( j )

Initializer:

\
                            MdtConstraintIsEnabled(MdtLinear2QuaConstraint(j))

#define MdtLinear2SetBodies( j, b1, b2 )

Initializer:

\
                            MdtConstraintSetBodies(MdtLinear2QuaConstraint(j), b1, b2)

#define MdtLinear2SetUserData( j, d )

Initializer:

\
                            MdtConstraintSetUserData(MdtLinear2QuaConstraint(j), d)

Function Documentation

MdtLinear2ID MdtLinear2Create ( MdtWorldID w,
MdtBodyID b1,
MdtBodyID b2 )

Creates a new linear 2 joint with default parameters.

See also:
MdtLinear2Reset()

void MdtLinear2Destroy ( MdtLinear2ID j )

Destroys a linear 2 joint.

void MdtLinear2GetDirection ( MdtLinear2ID j,
MeVector3 direction )

The linear 2 joint's direction vector is returned in v.

void MdtLinear2GetPosition ( MdtLinear2ID j,
MeVector3 position )

The linear 2 joint's position vector is returned in v.

void MdtLinear2Log ( MdtLinear2ID j )

Debug function - output constraint using MeMessage.

MdtConstraintID MdtLinear2QuaConstraint ( MdtLinear2ID j )

Gets an MdtConstraintID from a specific constraint for performing functions common to all constraints.

void MdtLinear2Reset ( MdtLinear2ID j )

Sets a linear2 joint to its default values.

Note that the joint's bodies are not reset.

Default values:

Parameters:
j   linear 2 joint ID

void MdtLinear2SetDirection ( MdtLinear2ID j,
MeReal x,
MeReal y,
MeReal z )

Sets the joint direction in world coordinates.

N.B. Set attributes x, y and z *should* be const.

void MdtLinear2SetPosition ( MdtLinear2ID j,
MeReal x,
MeReal y,
MeReal z )

Sets the joint position in world coordinates.


MathEngine Dynamics Toolkit - Version 0.0.5 Alpha - Reference Manual generated using doxygen at Wed Oct 11 00:34:48 2000

Copyright MathEngine PLC 2000, all rights reserved.