ph_setcorrections (var ERP, var CFM);

ph_setcollisions (var ERP, var CFM);

Sets global correction factors for physis constraints (ph_setcorrections) and physics collision contact points (ph_setcollisions). ERP stands for Error Reduction Parameter and defines how quickly misaligned constraints get adjusted. CFM means Contact Force Mixing and determines how 'soft' a constraint or collision contact reacts.

Parameters:

ERP Error Reduction Parameter [0..100000], default: 20000
CFM Contact Force Mixing [0..100000], default: 0.1

Returns:

1 if successful, 0 otherwise.

Speed:

Fast

Remarks:

Example:

ph_setcorrections(0,0); // switch off error correction for joints 
ph_setcollisions(20000, 100); // make collision contacts soft/spongy ph_setcollisions(100000, 0); // make collision contacts really hard

See also:

phent_setelasticity ► latest version online