Skip to content

Simulation: collision steps and integration steps #142

Answered by jrouwe
jankrassnigg asked this question in Q&A
Discussion options

You must be logged in to vote

I would leave the integration sub steps at 1. You can use it to make constraints stiffer / support stacking more objects on top of each other by effectively making the integration delta time smaller without paying the cost of an extra collision detection step. When I wrote it, I thought I could use it to run collision detection at 30 Hz and integration at 60 Hz, but that didn't really work, so I may actually remove it completely at some point.

W.r.t. to collision steps: Yes calling 2x Update(1/60, 1) is equivalent to calling Update(1/30, 2). The latter avoids a a little bit of overhead in preparing the job graph / locking the bodies, so is the preferred way.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by jrouwe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants