Fix wrong task priority for particle distribution and tanget computation
These kinds of depsgraph evaluations should not be marked as low priority as this could negatively affect playback performance. Low priority should mainly be used for background tasks.
This commit is contained in:
parent
5b2a6b6ebb
commit
e86b62f195
Notes:
blender-bot
2023-02-13 15:34:32 +01:00
Referenced by issue #97849, Blender 3.2 gpu shader overlay crash Referenced by issue #97854, overlay_shader_shared.h:XX:0: Error: C7011: implicit cast from "int" to "uint" Referenced by issue #97812, Blender 3.2 Beta Area & Spot Light gizmos not working as expected Referenced by issue #97737, GPU Subdivision: Crash after opening particular files
|
@ -342,7 +342,7 @@ void BKE_editmesh_loop_tangent_calc(BMEditMesh *em,
|
|||
/* Calculation */
|
||||
if (em->tottri != 0) {
|
||||
TaskPool *task_pool;
|
||||
task_pool = BLI_task_pool_create(NULL, TASK_PRIORITY_LOW);
|
||||
task_pool = BLI_task_pool_create(NULL, TASK_PRIORITY_HIGH);
|
||||
|
||||
tangent_mask_curr = 0;
|
||||
/* Calculate tangent layers */
|
||||
|
|
|
@ -620,7 +620,7 @@ void BKE_mesh_calc_loop_tangent_ex(const MVert *mvert,
|
|||
|
||||
/* Calculation */
|
||||
if (looptri_len != 0) {
|
||||
TaskPool *task_pool = BLI_task_pool_create(NULL, TASK_PRIORITY_LOW);
|
||||
TaskPool *task_pool = BLI_task_pool_create(NULL, TASK_PRIORITY_HIGH);
|
||||
|
||||
tangent_mask_curr = 0;
|
||||
/* Calculate tangent layers */
|
||||
|
|
|
@ -3194,7 +3194,7 @@ void psys_cache_child_paths(ParticleSimulationData *sim,
|
|||
return;
|
||||
}
|
||||
|
||||
task_pool = BLI_task_pool_create(&ctx, TASK_PRIORITY_LOW);
|
||||
task_pool = BLI_task_pool_create(&ctx, TASK_PRIORITY_HIGH);
|
||||
totchild = ctx.totchild;
|
||||
totparent = ctx.totparent;
|
||||
|
||||
|
|
|
@ -1313,7 +1313,7 @@ static void distribute_particles_on_dm(ParticleSimulationData *sim, int from)
|
|||
return;
|
||||
}
|
||||
|
||||
task_pool = BLI_task_pool_create(&ctx, TASK_PRIORITY_LOW);
|
||||
task_pool = BLI_task_pool_create(&ctx, TASK_PRIORITY_HIGH);
|
||||
|
||||
totpart = (from == PART_FROM_CHILD ? sim->psys->totchild : sim->psys->totpart);
|
||||
psys_tasks_create(&ctx, 0, totpart, &tasks, &numtasks);
|
||||
|
|
Loading…
Reference in New Issue