Blender V2.61 - r43446
|
A heap / priority queue ADT. More...
Go to the source code of this file.
Typedefs | |
typedef struct Heap | Heap |
typedef struct HeapNode | HeapNode |
typedef void(* | HeapFreeFP )(void *ptr) |
Functions | |
Heap * | BLI_heap_new (void) |
void | BLI_heap_free (Heap *heap, HeapFreeFP ptrfreefp) |
HeapNode * | BLI_heap_insert (Heap *heap, float value, void *ptr) |
void | BLI_heap_remove (Heap *heap, HeapNode *node) |
int | BLI_heap_empty (Heap *heap) |
int | BLI_heap_size (Heap *heap) |
HeapNode * | BLI_heap_top (Heap *heap) |
void * | BLI_heap_popmin (Heap *heap) |
float | BLI_heap_node_value (HeapNode *heap) |
void * | BLI_heap_node_ptr (HeapNode *heap) |
A heap / priority queue ADT.
Definition in file BLI_heap.h.
Definition at line 38 of file BLI_heap.h.
typedef void(* HeapFreeFP)(void *ptr) |
Definition at line 41 of file BLI_heap.h.
Definition at line 39 of file BLI_heap.h.
int BLI_heap_empty | ( | Heap * | heap | ) |
Definition at line 164 of file BLI_heap.c.
References Heap::size.
Referenced by edgetag_shortest_path(), and select_vertex_path_exec().
void BLI_heap_free | ( | Heap * | heap, |
HeapFreeFP | ptrfreefp | ||
) |
Definition at line 82 of file BLI_heap.c.
References Heap::arena, BLI_memarena_free(), i, MEM_freeN(), HeapNode::ptr, Heap::size, and Heap::tree.
Referenced by edgetag_shortest_path(), p_chart_fill_boundary(), select_vertex_path_exec(), and shortestPathsFromVert().
Definition at line 128 of file BLI_heap.c.
References Heap::arena, BLI_heap_up(), BLI_memarena_alloc(), Heap::bufsize, Heap::freenodes, HeapNode::index, MEM_freeN(), MEM_mallocN(), HeapNode::ptr, Heap::size, Heap::tree, and HeapNode::value.
Referenced by edgetag_add_adjacent(), edgetag_shortest_path(), p_chart_fill_boundary(), select_vertex_path_exec(), and shortestPathsFromVert().
Heap* BLI_heap_new | ( | void | ) |
Definition at line 72 of file BLI_heap.c.
References Heap::arena, BLI_memarena_new(), Heap::bufsize, MEM_callocN(), MEM_mallocN(), and Heap::tree.
Referenced by edgetag_shortest_path(), p_chart_fill_boundary(), select_vertex_path_exec(), and shortestPathsFromVert().
void* BLI_heap_node_ptr | ( | HeapNode * | heap | ) |
Definition at line 217 of file BLI_heap.c.
References HeapNode::ptr.
float BLI_heap_node_value | ( | HeapNode * | heap | ) |
Definition at line 212 of file BLI_heap.c.
References HeapNode::value.
Referenced by shortestPathsFromVert().
void* BLI_heap_popmin | ( | Heap * | heap | ) |
Definition at line 179 of file BLI_heap.c.
References BLI_heap_down(), Heap::freenodes, HEAP_SWAP, HeapNode::ptr, Heap::size, and Heap::tree.
Referenced by BLI_heap_remove(), edgetag_shortest_path(), p_chart_fill_boundary(), select_vertex_path_exec(), and shortestPathsFromVert().
Definition at line 198 of file BLI_heap.c.
References BLI_heap_popmin(), HEAP_PARENT, HEAP_SWAP, i, HeapNode::index, and p.
Referenced by p_chart_fill_boundary().
int BLI_heap_size | ( | Heap * | heap | ) |
Definition at line 169 of file BLI_heap.c.
References Heap::size.
Referenced by shortestPathsFromVert().
Definition at line 174 of file BLI_heap.c.
References Heap::tree.
Referenced by shortestPathsFromVert().