diff options
Diffstat (limited to 'source/blender/blenkernel/intern/object_update.cc')
-rw-r--r-- | source/blender/blenkernel/intern/object_update.cc | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/source/blender/blenkernel/intern/object_update.cc b/source/blender/blenkernel/intern/object_update.cc index ceef6404bf0..7ea13bfcc84 100644 --- a/source/blender/blenkernel/intern/object_update.cc +++ b/source/blender/blenkernel/intern/object_update.cc @@ -61,7 +61,7 @@ void BKE_object_eval_local_transform(Depsgraph *depsgraph, Object *ob) DEG_debug_print_eval(depsgraph, __func__, ob->id.name, ob); /* calculate local matrix */ - BKE_object_to_mat4(ob, ob->obmat); + BKE_object_to_mat4(ob, ob->object_to_world); } void BKE_object_eval_parent(Depsgraph *depsgraph, Object *ob) @@ -78,18 +78,18 @@ void BKE_object_eval_parent(Depsgraph *depsgraph, Object *ob) /* get local matrix (but don't calculate it, as that was done already!) */ /* XXX: redundant? */ - copy_m4_m4(locmat, ob->obmat); + copy_m4_m4(locmat, ob->object_to_world); /* get parent effect matrix */ BKE_object_get_parent_matrix(ob, par, totmat); /* total */ mul_m4_m4m4(tmat, totmat, ob->parentinv); - mul_m4_m4m4(ob->obmat, tmat, locmat); + mul_m4_m4m4(ob->object_to_world, tmat, locmat); /* origin, for help line */ if ((ob->partype & PARTYPE) == PARSKEL) { - copy_v3_v3(ob->runtime.parent_display_origin, par->obmat[3]); + copy_v3_v3(ob->runtime.parent_display_origin, par->object_to_world[3]); } else { copy_v3_v3(ob->runtime.parent_display_origin, totmat[3]); @@ -121,9 +121,9 @@ void BKE_object_eval_transform_final(Depsgraph *depsgraph, Object *ob) DEG_debug_print_eval(depsgraph, __func__, ob->id.name, ob); /* Make sure inverse matrix is always up to date. This way users of it * do not need to worry about recalculating it. */ - invert_m4_m4_safe(ob->imat, ob->obmat); + invert_m4_m4_safe(ob->imat, ob->object_to_world); /* Set negative scale flag in object. */ - if (is_negative_m4(ob->obmat)) { + if (is_negative_m4(ob->object_to_world)) { ob->transflag |= OB_NEG_SCALE; } else { @@ -257,7 +257,7 @@ void BKE_object_sync_to_original(Depsgraph *depsgraph, Object *object) /* Base flags. */ object_orig->base_flag = object->base_flag; /* Transformation flags. */ - copy_m4_m4(object_orig->obmat, object->obmat); + copy_m4_m4(object_orig->object_to_world, object->object_to_world); copy_m4_m4(object_orig->imat, object->imat); copy_m4_m4(object_orig->constinv, object->constinv); object_orig->transflag = object->transflag; @@ -292,6 +292,8 @@ void BKE_object_batch_cache_dirty_tag(Object *ob) BKE_lattice_batch_cache_dirty_tag((struct Lattice *)ob->data, BKE_LATTICE_BATCH_DIRTY_ALL); break; case OB_CURVES_LEGACY: + case OB_SURF: + case OB_FONT: BKE_curve_batch_cache_dirty_tag((struct Curve *)ob->data, BKE_CURVE_BATCH_DIRTY_ALL); break; case OB_MBALL: { |