Thanks for the elaborate information!
I was assuming job dependencies are likely the reason.
I believe the scene is rather simple:
- 1 BoxCollider (Ground)
- 1 MeshCollider using a distance field
- 1 to 8 Cloth actors with 32 particles each; closed convex shape with small particles; surface collisions are enabled because I need somewhat robust collisions between the actors:
Solver settings:
- Fixed timestep is around 0.033, the game is capped at 30 fps
I'm not modifying any simulation parameters at runtime, only evaluating the particle collisions.
I hope this information can be of use.
I was wondering if this code might lead to a situation where jobs are not scheduled when they could be?
I'm probably just misunderstanding the scheduling process.
I was assuming job dependencies are likely the reason.
I believe the scene is rather simple:
- 1 BoxCollider (Ground)
- 1 MeshCollider using a distance field
- 1 to 8 Cloth actors with 32 particles each; closed convex shape with small particles; surface collisions are enabled because I need somewhat robust collisions between the actors:
Solver settings:
- Fixed timestep is around 0.033, the game is capped at 30 fps
I'm not modifying any simulation parameters at runtime, only evaluating the particle collisions.
I hope this information can be of use.
I was wondering if this code might lead to a situation where jobs are not scheduled when they could be?
Code:
BurstConstraintsImpl.cs
public void ScheduleBatchedJobsIfNeeded()
{
if (scheduledJobCounter++ > 16)
{
scheduledJobCounter = 0;
JobHandle.ScheduleBatchedJobs();
}
}
I'm probably just misunderstanding the scheduling process.