Cleanup: Remove unused function, make function private

This commit is contained in:
Hans Goudey 2021-06-07 13:12:06 -05:00
parent 8cbff7093d
commit 1182c26978
2 changed files with 2 additions and 19 deletions

View File

@ -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);

View File

@ -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) {