pub unsafe extern "C" fn PxSceneSQSystem_sceneQueriesUpdate_mut(
    self_: *mut PxSceneSQSystem,
    completionTask: *mut PxBaseTask,
    controlSimulation: bool
)
Expand description

Executes scene queries update tasks.

This function will refit dirty shapes within the pruner and will execute a task to build a new AABB tree, which is build on a different thread. The new AABB tree is built based on the dynamic tree rebuild hint rate. Once the new tree is ready it will be commited in next fetchQueries call, which must be called after.

This function is equivalent to the following PxSceneQuerySystem calls: Synchronous calls:

  • PxSceneQuerySystemBase::flushUpdates()
  • handle0 = PxSceneQuerySystem::prepareSceneQueryBuildStep(PX_SCENE_PRUNER_STATIC)
  • handle1 = PxSceneQuerySystem::prepareSceneQueryBuildStep(PX_SCENE_PRUNER_DYNAMIC) Asynchronous calls:
  • PxSceneQuerySystem::sceneQueryBuildStep(handle0);
  • PxSceneQuerySystem::sceneQueryBuildStep(handle1);

This function is part of the PxSceneSQSystem interface because it uses the PxScene task system under the hood. But it calls PxSceneQuerySystem functions, which are independent from this system and could be called in a similar fashion by a separate, possibly user-defined task manager.

If PxSceneQueryUpdateMode::eBUILD_DISABLED_COMMIT_DISABLED is used, it is required to update the scene queries using this function.