| Safe Haskell | None |
|---|---|
| Language | GHC2021 |
Box2D.Joint
Synopsis
- destroy :: JointId -> Bool -> IO ()
- isValid :: JointId -> IO Bool
- getType :: JointId -> IO JointType
- getBodyA :: JointId -> IO BodyId
- getBodyB :: JointId -> IO BodyId
- getWorld :: JointId -> IO WorldId
- setLocalFrameA :: JointId -> Transform -> IO ()
- getLocalFrameA :: JointId -> IO Transform
- getLocalFrameAInto :: JointId -> Ptr Transform -> IO ()
- setLocalFrameB :: JointId -> Transform -> IO ()
- getLocalFrameB :: JointId -> IO Transform
- getLocalFrameBInto :: JointId -> Ptr Transform -> IO ()
- setCollideConnected :: JointId -> Bool -> IO ()
- getCollideConnected :: JointId -> IO Bool
- setUserData :: JointId -> Ptr () -> IO ()
- getUserData :: JointId -> IO (Ptr ())
- wakeBodies :: JointId -> IO ()
- getConstraintForce :: JointId -> IO Vec2
- getConstraintForceInto :: JointId -> Ptr Vec2 -> IO ()
- getConstraintTorque :: JointId -> IO Float
- getLinearSeparation :: JointId -> IO Float
- getAngularSeparation :: JointId -> IO Float
- setConstraintTuning :: JointId -> Float -> Float -> IO ()
- getConstraintTuning :: JointId -> Ptr Float -> Ptr Float -> IO ()
- setForceThreshold :: JointId -> Float -> IO ()
- getForceThreshold :: JointId -> IO Float
- setTorqueThreshold :: JointId -> Float -> IO ()
- getTorqueThreshold :: JointId -> IO Float
Documentation
Destroy a joint. Optionally wake attached bodies.
Binds b2DestroyJoint.
isValid :: JointId -> IO Bool Source #
Joint identifier validation. Provides validation for up to 64K allocations.
Binds b2Joint_IsValid.
Set the local frame on bodyA
Binds b2Joint_SetLocalFrameA.
getLocalFrameA :: JointId -> IO Transform Source #
Get the local frame on bodyA
Binds b2Joint_GetLocalFrameA.
Like getLocalFrameA, but the result is written into a caller-supplied buffer.
Set the local frame on bodyB
Binds b2Joint_SetLocalFrameB.
getLocalFrameB :: JointId -> IO Transform Source #
Get the local frame on bodyB
Binds b2Joint_GetLocalFrameB.
Like getLocalFrameB, but the result is written into a caller-supplied buffer.
Toggle collision between connected bodies
Binds b2Joint_SetCollideConnected.
getCollideConnected :: JointId -> IO Bool Source #
Is collision allowed between connected bodies?
Binds b2Joint_GetCollideConnected.
Set the user data on a joint
Binds b2Joint_SetUserData.
getUserData :: JointId -> IO (Ptr ()) Source #
Get the user data on a joint
Binds b2Joint_GetUserData.
wakeBodies :: JointId -> IO () Source #
Wake the bodies connect to this joint
Binds b2Joint_WakeBodies.
getConstraintForce :: JointId -> IO Vec2 Source #
Get the current constraint force for this joint. Usually in Newtons.
Binds b2Joint_GetConstraintForce.
getConstraintForceInto Source #
Like getConstraintForce, but the result is written into a caller-supplied buffer.
getConstraintTorque :: JointId -> IO Float Source #
Get the current constraint torque for this joint. Usually in Newton * meters.
Binds b2Joint_GetConstraintTorque.
getLinearSeparation :: JointId -> IO Float Source #
Get the current linear separation error for this joint. Does not consider admissible movement. Usually in meters.
Binds b2Joint_GetLinearSeparation.
getAngularSeparation :: JointId -> IO Float Source #
Get the current angular separation error for this joint. Does not consider admissible movement. Usually in meters.
Binds b2Joint_GetAngularSeparation.
Arguments
| :: JointId |
|
| -> Float |
|
| -> Float |
|
| -> IO () |
Set the joint constraint tuning. Advanced feature.
Binds b2Joint_SetConstraintTuning.
Get the joint constraint tuning. Advanced feature.
Binds b2Joint_GetConstraintTuning.
Set the force threshold for joint events (Newtons)
Binds b2Joint_SetForceThreshold.
getForceThreshold :: JointId -> IO Float Source #
Get the force threshold for joint events (Newtons)
Binds b2Joint_GetForceThreshold.
Set the torque threshold for joint events (N-m)
Binds b2Joint_SetTorqueThreshold.