|
We are trying to build up plugin to generate simple dynamics. We have a simulation that gives us satisfying results in realtime in the Viewport, when animation plays as well as when we manipulate objects in the Viewport.
However, when we plot our animation, the result generated is quite different from the realtime preview.
Anyone has any idea what the reason might be?
If this can help, we are using FBTime & GetSystemStart() in seconds as our time base.
Thanks in advance for your help !
|
|
|
|
Not sure if you are still interested in answer but:
Main problem is related to the time that you are using. For real-time its ok (as long as you dont want to sync simulation with animation). But for plotting in menu you specify the sampling rate. This is why you get different results. System time will let you know how long it took to evaluate last frame in plot, not how much time advanced. Easy fix could be to test in place where you query the time if you are in plot action (FBPlayerControl.IsPlotting) and then using local start time (FBEvaluateInfo.GetLocalStart()) if true.
Cheers!
|
|
|