C# Класс FarseerPhysics.Dynamics.Joints.GearJoint

A gear joint is used to connect two joints together. Either joint can be a revolute or prismatic joint. You specify a gear ratio to bind the motions together: coordinate1 + ratio * coordinate2 = ant The ratio can be negative or positive. If one joint is a revolute joint and the other joint is a prismatic joint, then the ratio will have units of length or units of 1/length. @warning The revolute and prismatic joints must be attached to fixed bodies (which must be body1 on those joints).
Наследование: Joint
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
GearJoint ( Body bodyA, Body bodyB, Joint jointA, Joint jointB, float ratio = 1f ) : System.Diagnostics

Requires two existing revolute or prismatic joints (any combination will work). The provided joints must attach a dynamic body to a static body.

getReactionForce ( float invDt ) : Vector2
getReactionTorque ( float invDt ) : float

Приватные методы

Метод Описание
initVelocityConstraints ( SolverData &data ) : void
solvePositionConstraints ( SolverData &data ) : bool
solveVelocityConstraints ( SolverData &data ) : void

Описание методов

GearJoint() публичный Метод

Requires two existing revolute or prismatic joints (any combination will work). The provided joints must attach a dynamic body to a static body.
public GearJoint ( Body bodyA, Body bodyB, Joint jointA, Joint jointB, float ratio = 1f ) : System.Diagnostics
bodyA Body The first body
bodyB Body The second body
jointA Joint The first joint.
jointB Joint The second joint.
ratio float The ratio.
Результат System.Diagnostics

getReactionForce() публичный Метод

public getReactionForce ( float invDt ) : Vector2
invDt float
Результат Vector2

getReactionTorque() публичный Метод

public getReactionTorque ( float invDt ) : float
invDt float
Результат float