diff options
Diffstat (limited to 'source/blender/blenkernel/BKE_depsgraph.h')
-rw-r--r-- | source/blender/blenkernel/BKE_depsgraph.h | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/source/blender/blenkernel/BKE_depsgraph.h b/source/blender/blenkernel/BKE_depsgraph.h index 6baf20aeb2c..be5ae7fc353 100644 --- a/source/blender/blenkernel/BKE_depsgraph.h +++ b/source/blender/blenkernel/BKE_depsgraph.h @@ -48,6 +48,21 @@ struct ID; struct Main; struct Object; struct Scene; +struct ListBase; + +/* Dependency graph evaluation context + * + * This structure stores all the local dependency graph data, + * which is needed for it's evaluation, + */ +typedef struct EvaluationContext { + bool for_render; /* Set to true if evaluation shall be performed for render purposes, + keep at false if update shall happen for the viewport. */ +} EvaluationContext; + +/* Global initialization/deinitialization */ +void DAG_init(void); +void DAG_exit(void); /* Build and Update * @@ -115,10 +130,30 @@ void DAG_pose_sort(struct Object *ob); void DAG_editors_update_cb(void (*id_func)(struct Main *bmain, struct ID *id), void (*scene_func)(struct Main *bmain, struct Scene *scene, int updated)); +/* ** Threaded update ** */ + +/* Initialize the DAG for threaded update. */ +void DAG_threaded_update_begin(struct Scene *scene, + void (*func)(void *node, void *user_data), + void *user_data); + +void DAG_threaded_update_handle_node_updated(void *node_v, + void (*func)(void *node, void *user_data), + void *user_data); + /* Debugging: print dependency graph for scene or armature object to console */ void DAG_print_dependencies(struct Main *bmain, struct Scene *scene, struct Object *ob); +/* Tagging and querying */ +void DAG_tag_clear_nodes(struct Scene *scene); +void DAG_tag_node_for_object(struct Scene *scene, void *object); +void DAG_tag_flush_nodes(struct Scene *scene); + +struct Object *DAG_get_node_object(void *node_v); +const char *DAG_get_node_name(void *node_v); +bool DAG_get_node_tag(void *node_v); + #ifdef __cplusplus } #endif |