Chipmunk  6.0.3
Chipmunk API Reference for Kobold2D developers
cpConstraint

Data Structures

struct  cpConstraintClass
struct  cpConstraint
 Opaque cpConstraint struct. More...

Defines

#define CP_DefineConstraintStructGetter(type, member, name)   static inline type cpConstraint##Get##name(const cpConstraint *constraint){return constraint->member;}
#define CP_DefineConstraintStructSetter(type, member, name)
#define CP_DefineConstraintStructProperty(type, member, name)

Typedefs

typedef void(* cpConstraintPreStepImpl )(cpConstraint *constraint, cpFloat dt)
typedef void(* cpConstraintApplyCachedImpulseImpl )(cpConstraint *constraint, cpFloat dt_coef)
typedef void(* cpConstraintApplyImpulseImpl )(cpConstraint *constraint)
typedef cpFloat(* cpConstraintGetImpulseImpl )(cpConstraint *constraint)
typedef void(* cpConstraintPreSolveFunc )(cpConstraint *constraint, cpSpace *space)
 Callback function type that gets called before solving a joint.
typedef void(* cpConstraintPostSolveFunc )(cpConstraint *constraint, cpSpace *space)
 Callback function type that gets called after solving a joint.

Functions

void cpConstraintDestroy (cpConstraint *constraint)
 Destroy a constraint.
void cpConstraintFree (cpConstraint *constraint)
 Destroy and free a constraint.
 CP_DefineConstraintStructGetter (cpBody *, a, A)
 CP_DefineConstraintStructGetter (cpBody *, b, B)
 CP_DefineConstraintStructProperty (cpFloat, maxForce, MaxForce)
 CP_DefineConstraintStructProperty (cpFloat, errorBias, ErrorBias)
 CP_DefineConstraintStructProperty (cpFloat, maxBias, MaxBias)
 CP_DefineConstraintStructProperty (cpConstraintPreSolveFunc, preSolve, PreSolveFunc)
 CP_DefineConstraintStructProperty (cpConstraintPostSolveFunc, postSolve, PostSolveFunc)
 CP_DefineConstraintStructProperty (cpDataPointer, data, UserData)
static cpFloat cpConstraintGetImpulse (cpConstraint *constraint)

Define Documentation

#define CP_DefineConstraintStructGetter (   type,
  member,
  name 
)    static inline type cpConstraint##Get##name(const cpConstraint *constraint){return constraint->member;}
#define CP_DefineConstraintStructProperty (   type,
  member,
  name 
)
Value:
CP_DefineConstraintStructGetter(type, member, name) \
CP_DefineConstraintStructSetter(type, member, name)
#define CP_DefineConstraintStructSetter (   type,
  member,
  name 
)
Value:
static inline void cpConstraint##Set##name(cpConstraint *constraint, type value){ \
    cpConstraintActivateBodies(constraint); \
    constraint->member = value; \
}

Typedef Documentation

typedef void(* cpConstraintApplyCachedImpulseImpl)(cpConstraint *constraint, cpFloat dt_coef)
typedef void(* cpConstraintApplyImpulseImpl)(cpConstraint *constraint)
typedef void(* cpConstraintPostSolveFunc)(cpConstraint *constraint, cpSpace *space)

Callback function type that gets called after solving a joint.

typedef void(* cpConstraintPreSolveFunc)(cpConstraint *constraint, cpSpace *space)

Callback function type that gets called before solving a joint.

typedef void(* cpConstraintPreStepImpl)(cpConstraint *constraint, cpFloat dt)

Function Documentation

CP_DefineConstraintStructGetter ( cpBody ,
,
 
)
CP_DefineConstraintStructGetter ( cpBody ,
,
 
)
CP_DefineConstraintStructProperty ( cpFloat  ,
maxForce  ,
MaxForce   
)
CP_DefineConstraintStructProperty ( cpFloat  ,
errorBias  ,
ErrorBias   
)
CP_DefineConstraintStructProperty ( cpFloat  ,
maxBias  ,
MaxBias   
)
CP_DefineConstraintStructProperty ( cpConstraintPreSolveFunc  ,
preSolve  ,
PreSolveFunc   
)
CP_DefineConstraintStructProperty ( cpConstraintPostSolveFunc  ,
postSolve  ,
PostSolveFunc   
)
CP_DefineConstraintStructProperty ( cpDataPointer  ,
data  ,
UserData   
)
void cpConstraintDestroy ( cpConstraint constraint)

Destroy a constraint.

void cpConstraintFree ( cpConstraint constraint)

Destroy and free a constraint.

static cpFloat cpConstraintGetImpulse ( cpConstraint constraint) [inline, static]