diff options
author | Germano Cavalcante <germano.costa@ig.com.br> | 2021-11-24 20:32:19 +0300 |
---|---|---|
committer | Germano Cavalcante <germano.costa@ig.com.br> | 2021-11-24 20:52:49 +0300 |
commit | 752c6d668bcb9a6b357734f7e124a6b605ac9d9b (patch) | |
tree | d71416b6e6dade5806a69705e188429af63fe7ec /source/blender/blenkernel/BKE_object.h | |
parent | 7a7ae4df436292345748ded71b2cefaf60a39fbd (diff) |
Fix T90808: wrong BoundBox after undo curve selection
There are two functions that recalculate the boundbox of an object:
- One that considers the evaluated geometry
- Another that only considers the object's `data`.
Most of the time, the bound box is calculated on the final object
(with modifiers), so it doesn't seem right to just rely on `ob->data`
to recalculate the `ob->runtime.bb`.
Be sure to calculate the BoundBox based on the final geometry and
only use `ob->data` as a fallback
Differential Revision: https://developer.blender.org/D12282
Diffstat (limited to 'source/blender/blenkernel/BKE_object.h')
-rw-r--r-- | source/blender/blenkernel/BKE_object.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/blenkernel/BKE_object.h b/source/blender/blenkernel/BKE_object.h index 4e53af5562f..6e1486be0be 100644 --- a/source/blender/blenkernel/BKE_object.h +++ b/source/blender/blenkernel/BKE_object.h @@ -240,6 +240,7 @@ void BKE_object_dimensions_set(struct Object *ob, const float value[3], int axis void BKE_object_empty_draw_type_set(struct Object *ob, const int value); void BKE_object_boundbox_flag(struct Object *ob, int flag, const bool set); void BKE_object_boundbox_calc_from_mesh(struct Object *ob, const struct Mesh *me_eval); +bool BKE_object_boundbox_calc_from_evaluated_geometry(struct Object *ob); void BKE_object_minmax(struct Object *ob, float r_min[3], float r_max[3], const bool use_hidden); bool BKE_object_minmax_dupli(struct Depsgraph *depsgraph, struct Scene *scene, |