Blender Git Loki

Git Commits -> Revision 1abd978

October 1, 2015, 18:44 (GMT)
BLI_task: add optional 'forced background' behavior to pools, and freefunc to tasks.

Currently, task scheduler in mono-threaded context do not have any worker thread,
which means you have to 'work_and_wait' on a pool to get its tasks done in this context.
This is not suitable for that are to be done in a complete asynchronous, background
fashion, so this commit adds:
* One worker thread to scheduler in case none is created by default;
* That worker thread only execute tasks from pools which have relevant option set
(so-called 'forced background' pools).

This commit also adds an optional freefunc callback to tasks, in case we need
more sofisticated behavior that a mere MEM_freeN...

Commit Details:

Full Hash: 1abd97850373ac3372331464be8e0f5eb8b98279
Parent Commit: 550527b
Lines Changed: +102, -31

15 Modified Paths:

/source/blender/blenkernel/intern/mesh_evaluate.c (+1, -1) (Diff)
/source/blender/blenkernel/intern/particle.c (+1, -1) (Diff)
/source/blender/blenkernel/intern/particle_distribute.c (+1, -1) (Diff)
/source/blender/blenkernel/intern/scene.c (+1, -1) (Diff)
/source/blender/blenlib/BLI_task.h (+5, -1) (Diff)
/source/blender/blenlib/intern/task.c (+84, -17) (Diff)
/source/blender/depsgraph/intern/depsgraph_eval.cc (+1, -1) (Diff)
/source/blender/editors/armature/editarmature_retarget.c (+1, -1) (Diff)
/source/blender/editors/mask/mask_draw.c (+1, -1) (Diff)
/source/blender/editors/space_clip/clip_editor.c (+1, -1) (Diff)
/source/blender/editors/space_clip/clip_ops.c (+1, -1) (Diff)
/source/blender/editors/space_file/filelist.c (+1, -1) (Diff)
/source/blender/imbuf/intern/imageprocess.c (+1, -1) (Diff)
/source/blender/render/intern/source/volume_precache.c (+1, -1) (Diff)
/source/gameengine/Ketsji/KX_Scene.cpp (+1, -1) (Diff)
Tehnyt: Miika HämäläinenViimeksi päivitetty: 07.11.2014 14:18MiikaH:n Sivut a.k.a. MiikaHweb | 2003-2021