[Bf-blender-cvs] [aad711d0642] blender2.8: Merge branch 'master' into blender2.8

Sergey Sharybin noreply at git.blender.org
Wed Nov 29 15:47:17 CET 2017


Commit: aad711d06428545c415b277fb6cf899a1cf1c03a
Author: Sergey Sharybin
Date:   Wed Nov 29 15:47:00 2017 +0100
Branches: blender2.8
https://developer.blender.org/rBaad711d06428545c415b277fb6cf899a1cf1c03a

Merge branch 'master' into blender2.8

===================================================================



===================================================================

diff --cc source/blender/blenkernel/BKE_object.h
index 31125545670,2772b3e2e6b..e446451d999
--- a/source/blender/blenkernel/BKE_object.h
+++ b/source/blender/blenkernel/BKE_object.h
@@@ -205,27 -200,19 +205,32 @@@ void BKE_object_eval_cloth(const struc
                             struct Scene *scene,
                             struct Object *object);
  
 -
+ void BKE_object_eval_transform_all(struct EvaluationContext *eval_ctx,
+                                    struct Scene *scene,
+                                    struct Object *object);
+ 
 -void BKE_object_handle_data_update(struct EvaluationContext *eval_ctx,
 -                                   struct Scene *scene,
 -                                   struct Object *ob);
 -void BKE_object_handle_update(struct EvaluationContext *eval_ctx, struct Scene *scene, struct Object *ob);
 -void BKE_object_handle_update_ex(struct EvaluationContext *eval_ctx,
 -                                 struct Scene *scene, struct Object *ob,
 -                                 struct RigidBodyWorld *rbw,
 -                                 const bool do_proxy_update);
 +void BKE_object_eval_update_shading(const struct EvaluationContext *eval_ctx,
 +                                    struct Object *object);
 +void BKE_object_data_select_update(const struct EvaluationContext *eval_ctx,
 +                                   struct ID *object_data);
 +
 +void BKE_object_eval_flush_base_flags(const struct EvaluationContext *eval_ctx,
 +                                      struct Object *object, struct Base *base,
 +                                      const bool is_from_set);
 +
 +void BKE_object_handle_data_update(
 +        const struct EvaluationContext *eval_ctx,
 +        struct Scene *scene,
 +        struct Object *ob);
 +void BKE_object_handle_update(
 +        const struct EvaluationContext *eval_ctx,
 +        struct Scene *scene, struct Object *ob);
 +void BKE_object_handle_update_ex(
 +        const struct EvaluationContext *eval_ctx,
 +        struct Scene *scene, struct Object *ob,
 +        struct RigidBodyWorld *rbw,
 +        const bool do_proxy_update);
++
  void BKE_object_sculpt_modifiers_changed(struct Object *ob);
  
  int BKE_object_obdata_texspace_get(struct Object *ob, short **r_texflag, float **r_loc, float **r_size, float **r_rot);
diff --cc source/blender/blenkernel/intern/object_update.c
index 1e8de416ea9,fd2b5ff589f..4d2cf0c5dc6
--- a/source/blender/blenkernel/intern/object_update.c
+++ b/source/blender/blenkernel/intern/object_update.c
@@@ -391,50 -343,18 +391,66 @@@ void BKE_object_eval_cloth(const Evalua
  	BKE_ptcache_object_reset(scene, object, PTCACHE_RESET_DEPSGRAPH);
  }
  
+ void BKE_object_eval_transform_all(EvaluationContext *eval_ctx,
+                                    Scene *scene,
+                                    Object *object)
+ {
+ 	/* This mimics full transform update chain from new depsgraph. */
+ 	BKE_object_eval_local_transform(eval_ctx, scene, object);
+ 	if (object->parent != NULL) {
+ 		BKE_object_eval_parent(eval_ctx, scene, object);
+ 	}
+ 	if (!BLI_listbase_is_empty(&object->constraints)) {
+ 		BKE_object_eval_constraints(eval_ctx, scene, object);
+ 	}
+ 	BKE_object_eval_uber_transform(eval_ctx, scene, object);
+ 	BKE_object_eval_done(eval_ctx, object);
+ }
++
 +void BKE_object_eval_update_shading(const EvaluationContext *UNUSED(eval_ctx),
 +                                    Object *object)
 +{
 +	DEBUG_PRINT("%s on %s (%p)\n", __func__, object->id.name, object);
 +	if (object->type == OB_MESH) {
 +		BKE_mesh_batch_cache_dirty(object->data, BKE_MESH_BATCH_DIRTY_SHADING);
 +	}
 +}
 +
 +void BKE_object_data_select_update(const EvaluationContext *UNUSED(eval_ctx),
 +                                   struct ID *object_data)
 +{
 +	DEBUG_PRINT("%s on %s (%p)\n", __func__, object_data->name, object_data);
 +	switch (GS(object_data->name)) {
 +		case ID_ME:
 +			BKE_mesh_batch_cache_dirty((Mesh *)object_data,
 +			                           BKE_CURVE_BATCH_DIRTY_SELECT);
 +			break;
 +		case ID_CU:
 +			BKE_curve_batch_cache_dirty((Curve *)object_data,
 +			                            BKE_CURVE_BATCH_DIRTY_SELECT);
 +			break;
 +		case ID_LT:
 +			BKE_lattice_batch_cache_dirty((struct Lattice *)object_data,
 +			                              BKE_CURVE_BATCH_DIRTY_SELECT);
 +			break;
 +		default:
 +			break;
 +	}
 +}
 +
 +void BKE_object_eval_flush_base_flags(const EvaluationContext *UNUSED(eval_ctx),
 +                                      Object *object, Base *base, bool is_from_set)
 +{
 +	DEBUG_PRINT("%s on %s (%p)\n", __func__, object->id.name, object);
 +	/* Make sure we have the base collection settings is already populated.
 +	 * This will fail when BKE_layer_eval_layer_collection_pre hasn't run yet
 +	 * Which usually means a missing call to DEG_id_tag_update(). */
 +	BLI_assert(!BLI_listbase_is_empty(&base->collection_properties->data.group));
 +	/* Copy flags and settings from base. */
 +	object->base_flag = base->flag;
 +	if (is_from_set) {
 +		object->base_flag |= BASE_FROM_SET;
 +		object->base_flag &= ~(BASE_SELECTED | BASE_SELECTABLED);
 +	}
 +	object->base_collection_properties = base->collection_properties;
 +}



More information about the Bf-blender-cvs mailing list