Public Member Functions | Public Attributes

bl7::rigidbodies2::Cable Class Reference

#include <Cable.h>

Inheritance diagram for bl7::rigidbodies2::Cable:
bl7::rigidbodies2::Link bl7::rigidbodies2::ContactGenerator

List of all members.

Public Member Functions

virtual ~Cable (void)
 Cable (RigidBody *body, const ml7::Vector2 &local_point, const ml7::Vector2 &world_point, const float length, const float restitution)
 Cable (RigidBody *body1, RigidBody *body2, const ml7::Vector2 &local_point1, const ml7::Vector2 &local_point2, const float length, const float restitution)
float get_length () const
float get_restitution () const
void set_length (const float length)
void set_restitution (const float restitution)

Public Attributes

float _max_length
float _restitution

Detailed Description

A contact generator that generates a contact if the cable connecting two rigid bodies (or one rigid body with the world) is overextended.


Constructor & Destructor Documentation

virtual bl7::rigidbodies2::Cable::~Cable ( void   )  [inline, virtual]

Destructor.

bl7::rigidbodies2::Cable::Cable ( RigidBody body,
const ml7::Vector2 local_point,
const ml7::Vector2 world_point,
const float  length,
const float  restitution 
) [inline]

Explicit constructor with parameters for the rigid body linked to the world, the local connection point as well as the world connection point and the length and the restitution ("bounciness" of the cable).

bl7::rigidbodies2::Cable::Cable ( RigidBody body1,
RigidBody body2,
const ml7::Vector2 local_point1,
const ml7::Vector2 local_point2,
const float  length,
const float  restitution 
) [inline]

Explicit constructor with parameters for the rigid bodies linked together, the local connection points as well as the length and the restitution ("bounciness" of the cable).


Member Function Documentation

float bl7::rigidbodies2::Cable::get_length (  )  const [inline]

Returns the maximum length of the cable.

float bl7::rigidbodies2::Cable::get_restitution (  )  const [inline]

Returns the restitution (bounciness) of the cable.

void bl7::rigidbodies2::Cable::set_length ( const float  length  )  [inline]

Sets the maximum length of the cable.

void bl7::rigidbodies2::Cable::set_restitution ( const float  restitution  )  [inline]

Sets the restitution (bounciness) of the cable.


Member Data Documentation

The maximum length of the cable.

The restitution (bounciness) of the cable.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines