++ed by:
GARU

1 PAUSE user(s)
1 non-PAUSE user(s).

Jeffrey T. Palmer
and 1 contributors

NAME

Box2D::b2GearJointDef - Gear joint definition.

SYNOPSIS

  my $joint_def = Box2D::b2GearJointDef->new();
  $joint_def->bodyA( $body_a );
  $joint_def->bodyB( $body_b );
  $joint_def->joint1( $joint1 );
  $joint_def->joint2( $joint2 );
  $joint_def->ratio( $ratio );
  my $joint = $world->CreateJoint( $joint_def );

DESCRIPTION

Gear joint definition. This definition requires two existing revolute or prismatic joints (any combination will work). The provided joints must attach a dynamic body to a static body.

METHODS

new()

Default constructor.

Returns a Box2D::b2GearJointDef

joint1()

joint1( $joint1 )

The first revolute/prismatic joint attached to the gear joint.

Parameters:

  • Box2D::b2Joint* $joint1 (optional)

Returns a Box2D::b2Joint*

joint2()

joint2( $joint2 )

The second revolute/prismatic joint attached to the gear joint.

Parameters:

  • Box2D::b2Joint* $joint2 (optional)

Returns a Box2D::b2Joint*

ratio()

ratio( $ratio )

The gear ratio.

See also: Box2D::b2GearJoint for explanation.

Parameters:

  • float32 $ratio (optional)

Returns a float32

SEE ALSO

BUGS

See "BUGS" in Box2D

AUTHORS

See "AUTHORS" in Box2D

COPYRIGHT & LICENSE

See "COPYRIGHT & LICENSE" in Box2D