Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Running Obi Cloth In Edit Mode
#3
(22-12-2020, 10:16 AM)josemendez Wrote: Hi there,

You can derive from the ObiUpdater class to update Obi whenever you want, including at edit time. See:
http://obi.virtualmethodstudio.com/tutor...aters.html

Also look up ObiUpdater in the API docs:
http://obi.virtualmethodstudio.com/api.html

You'll see it has several methods to advance the simulation: BeginStep, Substep, EndStep, and Interpolate. You can also check the different existing subclasses of ObiUpdater (ObiFixedUpdater, ObiLateUpdater, etc) for examples on how/when to call these methods. The typical pattern would be:

Code:
BeginStep();
Substep();
Substep();
.
.
.
Substep();
EndStep();
Interpolate();

So: one call to BeginStep() (performs collision detection and clears up cached data), one or more calls to Substep() (advances simulation), one call to EndStep(); (calls collision callbacks) and one call to Interpolate(); (interpolates physics state and triggers rendering).

cheers!
Hi, I tried bu unity crashes at m_SolverImpl.CollisionDetection(stepTime) at line 1396 in  obiolver. I could not figure out. I have modified FixedUpdater to run in EditMode.
Reply


Messages In This Thread
Running Obi Cloth In Edit Mode - by berko - 22-12-2020, 10:07 AM
RE: Running Obi Cloth In Edit Mode - by berko - 22-12-2020, 09:49 PM
RE: Running Obi Cloth In Edit Mode - by berko - 23-12-2020, 09:32 AM