Obi  6.4
Unified particle physics for Unity
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events Pages
Obi.ObiFixedUpdater Class Reference

Updater class that will perform simulation during FixedUpdate(). This is the most physically correct updater, and the one to be used in most cases. Also allows to perform substepping, greatly improving convergence. More...

Inheritance diagram for Obi.ObiFixedUpdater:
Obi.ObiUpdater

Public Attributes

int substeps = 4
 Each FixedUpdate() call will be divided into several substeps. Performing more substeps will greatly improve the accuracy/convergence speed of the simulation. Increasing the amount of substeps is more effective than increasing the amount of constraint iterations. More...
 
- Public Attributes inherited from Obi.ObiUpdater
List< ObiSolversolvers = new List<ObiSolver>()
 List of solvers updated by this updater. More...
 

Additional Inherited Members

- Protected Member Functions inherited from Obi.ObiUpdater
void PrepareFrame ()
 Prepares all solvers to begin simulating a new frame. This should be called as soon as possible in the frame, and guaranteed to be called every frame that will step physics. More...
 
void BeginStep (float stepDeltaTime)
 Prepares all solvers to begin simulating a new physics step. This involves caching some particle data for interpolation, performing collision detection, among other things. More...
 
void Substep (float stepDeltaTime, float substepDeltaTime, int index)
 Advances the simulation a given amount of time. Note that once BeginStep has been called, Substep can be called multiple times. More...
 
void EndStep (float substepDeltaTime)
 Wraps up the current simulation step. This will trigger contact callbacks. More...
 
void Interpolate (float stepDeltaTime, float accumulatedTime)
 Interpolates the previous and current physics states. Should be called right before rendering the current frame. More...
 

Detailed Description

Updater class that will perform simulation during FixedUpdate(). This is the most physically correct updater, and the one to be used in most cases. Also allows to perform substepping, greatly improving convergence.

Member Data Documentation

int Obi.ObiFixedUpdater.substeps = 4

Each FixedUpdate() call will be divided into several substeps. Performing more substeps will greatly improve the accuracy/convergence speed of the simulation. Increasing the amount of substeps is more effective than increasing the amount of constraint iterations.


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