diff options
Diffstat (limited to 'source/blender/depsgraph')
-rw-r--r-- | source/blender/depsgraph/DEG_depsgraph.h | 4 | ||||
-rw-r--r-- | source/blender/depsgraph/intern/depsgraph_eval.cc | 4 | ||||
-rw-r--r-- | source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc | 3 |
3 files changed, 3 insertions, 8 deletions
diff --git a/source/blender/depsgraph/DEG_depsgraph.h b/source/blender/depsgraph/DEG_depsgraph.h index 5cd1b48e80e..43fb83e205b 100644 --- a/source/blender/depsgraph/DEG_depsgraph.h +++ b/source/blender/depsgraph/DEG_depsgraph.h @@ -75,8 +75,6 @@ typedef enum eEvaluationMode { DAG_EVAL_RENDER = 2, /* evaluate for render purposes */ } eEvaluationMode; -#include "DNA_object_enums.h" - /* Dependency graph evaluation context * * This structure stores all the local dependency graph data, @@ -85,7 +83,6 @@ typedef enum eEvaluationMode { typedef struct EvaluationContext { eEvaluationMode mode; float ctime; - eObjectMode object_mode; struct Depsgraph *depsgraph; struct ViewLayer *view_layer; @@ -221,7 +218,6 @@ void DEG_evaluation_context_init_from_scene( struct Scene *scene, struct ViewLayer *view_layer, struct RenderEngineType *engine_type, - const eObjectMode object_mode, eEvaluationMode mode); void DEG_evaluation_context_init_from_view_layer_for_render( diff --git a/source/blender/depsgraph/intern/depsgraph_eval.cc b/source/blender/depsgraph/intern/depsgraph_eval.cc index d76eba29628..0b3e4fd8db9 100644 --- a/source/blender/depsgraph/intern/depsgraph_eval.cc +++ b/source/blender/depsgraph/intern/depsgraph_eval.cc @@ -84,7 +84,6 @@ void DEG_evaluation_context_init_from_scene( Scene *scene, ViewLayer *view_layer, RenderEngineType *engine_type, - eObjectMode object_mode, eEvaluationMode mode) { DEG_evaluation_context_init(eval_ctx, mode); @@ -92,7 +91,6 @@ void DEG_evaluation_context_init_from_scene( eval_ctx->view_layer = view_layer; eval_ctx->engine_type = engine_type; eval_ctx->ctime = BKE_scene_frame_get(scene); - eval_ctx->object_mode = object_mode; } void DEG_evaluation_context_init_from_view_layer_for_render( @@ -107,7 +105,6 @@ void DEG_evaluation_context_init_from_view_layer_for_render( DEG_evaluation_context_init(eval_ctx, DAG_EVAL_RENDER); eval_ctx->ctime = BKE_scene_frame_get(scene); - eval_ctx->object_mode = OB_MODE_OBJECT; eval_ctx->depsgraph = depsgraph; eval_ctx->view_layer = view_layer_original; eval_ctx->engine_type = NULL; @@ -121,7 +118,6 @@ void DEG_evaluation_context_init_from_depsgraph( Scene *scene = DEG_get_evaluated_scene(depsgraph); DEG_evaluation_context_init(eval_ctx, mode); eval_ctx->ctime = (float)scene->r.cfra + scene->r.subframe; - eval_ctx->object_mode = OB_MODE_OBJECT; eval_ctx->depsgraph = depsgraph; eval_ctx->view_layer = DEG_get_evaluated_view_layer(depsgraph); eval_ctx->engine_type = NULL; diff --git a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc index 6cbd6b62851..64f5caccb0c 100644 --- a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc +++ b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc @@ -437,9 +437,11 @@ void update_special_pointers(const Depsgraph *depsgraph, * new copy of the object. */ Object *object_cow = (Object *)id_cow; + const Object *object_orig = (const Object *)id_orig; (void) object_cow; /* Ignored for release builds. */ BLI_assert(object_cow->derivedFinal == NULL); BLI_assert(object_cow->derivedDeform == NULL); + object_cow->mode = object_orig->mode; break; } case ID_ME: @@ -634,6 +636,7 @@ void update_copy_on_write_object(const Depsgraph * /*depsgraph*/, extract_pose_from_pose(pose_cow, pose_orig); /* Update object itself. */ BKE_object_transform_copy(object_cow, object_orig); + object_cow->mode = object_orig->mode; } /* Update copy-on-write version of datablock from it's original ID without re-building |