# b2GearJointDef Struct Reference

`#include <b2GearJoint.h>`

Inheritance diagram for b2GearJointDef:

List of all members.

## Public Member Functions
| b2GearJointDef ()
## Public Attributes
b2Joint * | joint1
| The first revolute/prismatic joint attached to the gear joint.
b2Joint * | joint2
| The second revolute/prismatic joint attached to the gear joint.
float32 | ratio

## Detailed 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.

## Constructor & Destructor Documentation

b2GearJointDef::b2GearJointDef | ( |  | ) | `[inline]`

## Member Data Documentation

b2Joint* b2GearJointDef::joint1

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

b2Joint* b2GearJointDef::joint2

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

float32 b2GearJointDef::ratio

The gear ratio.

See also:
  b2GearJoint for explanation.

The documentation for this struct was generated from the following file:

- Box2D/Box2D/Dynamics/Joints/b2GearJoint.h