Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2018-02-15 15:36:11 +0300
committerCampbell Barton <ideasman42@gmail.com>2018-02-15 15:39:08 +0300
commitccdacf1c9b31b15e188aa9e9adb044ffd0ca0da4 (patch)
tree086fc08c0a7d7ecefb4ed6666a3c2fd813142c8b /source/blender/editors/uvedit
parent4da6c496137042d4c90292f5567a6702a3df3323 (diff)
Cleanup: use '_len' instead of '_size' w/ BLI API
- When returning the number of items in a collection use BLI_*_len() - Keep _size() for size in bytes. - Keep _count() for data structures that don't store length (hint this isn't a simple getter). See P611 to apply instead of manually resolving conflicts.
Diffstat (limited to 'source/blender/editors/uvedit')
-rw-r--r--source/blender/editors/uvedit/uvedit_parametrizer.c4
-rw-r--r--source/blender/editors/uvedit/uvedit_smart_stitch.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/uvedit/uvedit_parametrizer.c b/source/blender/editors/uvedit/uvedit_parametrizer.c
index 2a3a2b84223..f8a93bd2ce3 100644
--- a/source/blender/editors/uvedit/uvedit_parametrizer.c
+++ b/source/blender/editors/uvedit/uvedit_parametrizer.c
@@ -1291,7 +1291,7 @@ static void p_chart_fill_boundary(PChart *chart, PEdge *be, int nedges)
while (nedges > 2) {
PEdge *ne, *ne1, *ne2;
- e = (PEdge *)BLI_heap_popmin(heap);
+ e = (PEdge *)BLI_heap_pop_min(heap);
e1 = p_boundary_edge_prev(e);
e2 = p_boundary_edge_next(e);
@@ -2190,7 +2190,7 @@ static void p_chart_simplify_compute(PChart *chart)
break;
HeapNode *link = BLI_heap_top(heap);
- PEdge *edge = (PEdge *)BLI_heap_popmin(heap), *pair = edge->pair;
+ PEdge *edge = (PEdge *)BLI_heap_pop_min(heap), *pair = edge->pair;
PVert *oldv, *keepv;
PEdge *wheele, *nexte;
diff --git a/source/blender/editors/uvedit/uvedit_smart_stitch.c b/source/blender/editors/uvedit/uvedit_smart_stitch.c
index c2a38a90621..da36170310a 100644
--- a/source/blender/editors/uvedit/uvedit_smart_stitch.c
+++ b/source/blender/editors/uvedit/uvedit_smart_stitch.c
@@ -1782,7 +1782,7 @@ static int stitch_init(bContext *C, wmOperator *op)
}
}
- total_edges = BLI_ghash_size(edge_hash);
+ total_edges = BLI_ghash_len(edge_hash);
state->edges = edges = MEM_mallocN(sizeof(*edges) * total_edges, "stitch_edges");
/* I assume any system will be able to at least allocate an iterator :p */