[Bf-blender-cvs] [69c07adb518] master: Cleanup: Remove object bounding box function

Hans Goudey noreply at git.blender.org
Fri Apr 1 21:58:42 CEST 2022


Commit: 69c07adb51832950643f558dff671b55cc8706cd
Author: Hans Goudey
Date:   Fri Apr 1 14:58:32 2022 -0500
Branches: master
https://developer.blender.org/rB69c07adb51832950643f558dff671b55cc8706cd

Cleanup: Remove object bounding box function

This abstraction doesn't serve any purpose after 11c6d4e88eb919.
The flag on bounding boxes isn't used, except for the dirty tag.

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

M	source/blender/blenkernel/BKE_object.h
M	source/blender/blenkernel/intern/object.cc

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

diff --git a/source/blender/blenkernel/BKE_object.h b/source/blender/blenkernel/BKE_object.h
index e36d71602e3..2d60ce87e23 100644
--- a/source/blender/blenkernel/BKE_object.h
+++ b/source/blender/blenkernel/BKE_object.h
@@ -355,10 +355,7 @@ void BKE_object_dimensions_set_ex(struct Object *ob,
 void BKE_object_dimensions_set(struct Object *ob, const float value[3], int axis_mask);
 
 void BKE_object_empty_draw_type_set(struct Object *ob, int value);
-/**
- * Use this to temporally disable/enable bound-box.
- */
-void BKE_object_boundbox_flag(struct Object *ob, int flag, 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], bool use_hidden);
diff --git a/source/blender/blenkernel/intern/object.cc b/source/blender/blenkernel/intern/object.cc
index 4679e643b01..62c6a6aab98 100644
--- a/source/blender/blenkernel/intern/object.cc
+++ b/source/blender/blenkernel/intern/object.cc
@@ -3627,19 +3627,6 @@ BoundBox *BKE_object_boundbox_get(Object *ob)
   return bb;
 }
 
-void BKE_object_boundbox_flag(Object *ob, int flag, const bool set)
-{
-  BoundBox *bb = BKE_object_boundbox_get(ob);
-  if (bb) {
-    if (set) {
-      bb->flag |= flag;
-    }
-    else {
-      bb->flag &= ~flag;
-    }
-  }
-}
-
 void BKE_object_boundbox_calc_from_mesh(Object *ob, const Mesh *me_eval)
 {
   float3 min(FLT_MAX);



More information about the Bf-blender-cvs mailing list