I know I can use Space.Update(float dt) to let BEPU handle proper timesteps internally and can afterwards access interpolated state with the BufferedStates.InterpolatedStates properties. However, I'd like to handle timesteps myself outside BEPU (e.g. to collect input for each physics timestep) and will use Space.Update() to calculate each physics step individually.
Can I still use the interpolated states then? I've already seen the Space.BufferedStates.InterpolatedStates.BlendAmount property and guess I'll just need to set that manually (and enable BufferedStates and InterpolatedStates). E.g. if I simulate a new physics step for every 16ms (60fps) and I've got 8ms remaining in my frametime accumulator, I'll simply set BlendAmount to 0.5 and can safely use the interpolated states for rendering!?
Using interpolated states with external timesteps
Re: Using interpolated states with external timesteps
That should work. The space's interpolated states manager will need to be enabled, and its Update method has to be called in order for the states to actually change. That's basically all the Space.Update(dt) method does.E.g. if I simulate a new physics step for every 16ms (60fps) and I've got 8ms remaining in my frametime accumulator, I'll simply set BlendAmount to 0.5 and can safely use the interpolated states for rendering!?
Another option would be to hook an event on one of the per timestep events (any of the space update stages Finished events would work) or make a custom Updateable so that your code runs on timesteps called by the built in accumulator. This isn't a strictly better way really, just another option.
Re: Using interpolated states with external timesteps
Thanks, I probably would have missed the InterpolatedStates.Update() method. Seems to work great now 
