diff options
author | Hans Goudey <h.goudey@me.com> | 2021-06-07 21:12:06 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2021-06-07 21:12:06 +0300 |
commit | 1182c269787dd73a20ef5c524325ff60918bb02d (patch) | |
tree | d3b8b151f3db6fc8ae65ee77000755ffda75099b /source | |
parent | 8cbff7093d658661e8f8f242552a4de95a9fbc64 (diff) |
Cleanup: Remove unused function, make function private
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/BKE_displist.h | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/displist.cc | 19 |
2 files changed, 2 insertions, 19 deletions
diff --git a/source/blender/blenkernel/BKE_displist.h b/source/blender/blenkernel/BKE_displist.h index 23f01bc0d02..459db9415af 100644 --- a/source/blender/blenkernel/BKE_displist.h +++ b/source/blender/blenkernel/BKE_displist.h @@ -78,8 +78,6 @@ typedef struct DispList { } DispList; void BKE_displist_copy(struct ListBase *lbn, const struct ListBase *lb); -void BKE_displist_elem_free(DispList *dl); -DispList *BKE_displist_find_or_create(struct ListBase *lb, int type); DispList *BKE_displist_find(struct ListBase *lb, int type); void BKE_displist_normals_add(struct ListBase *lb); void BKE_displist_count(const struct ListBase *lb, int *totvert, int *totface, int *tottri); diff --git a/source/blender/blenkernel/intern/displist.cc b/source/blender/blenkernel/intern/displist.cc index 8200dc82dbc..f9536f11227 100644 --- a/source/blender/blenkernel/intern/displist.cc +++ b/source/blender/blenkernel/intern/displist.cc @@ -65,7 +65,7 @@ using blender::IndexRange; static void boundbox_displist_object(Object *ob); -void BKE_displist_elem_free(DispList *dl) +static void displist_elem_free(DispList *dl) { if (dl) { if (dl->verts) { @@ -86,25 +86,10 @@ void BKE_displist_free(ListBase *lb) DispList *dl; while ((dl = (DispList *)BLI_pophead(lb))) { - BKE_displist_elem_free(dl); + displist_elem_free(dl); } } -DispList *BKE_displist_find_or_create(ListBase *lb, int type) -{ - LISTBASE_FOREACH (DispList *, dl, lb) { - if (dl->type == type) { - return dl; - } - } - - DispList *dl = (DispList *)MEM_callocN(sizeof(DispList), "find_disp"); - dl->type = type; - BLI_addtail(lb, dl); - - return dl; -} - DispList *BKE_displist_find(ListBase *lb, int type) { LISTBASE_FOREACH (DispList *, dl, lb) { |