|
Blender V4.3
|
Go to the source code of this file.
Macros | |
| #define | STACK_DECLARE(stack) unsigned int _##stack##_index, _##stack##_num_alloc |
| #define | STACK_INIT(stack, stack_num) |
| #define | _STACK_SIZETEST(stack, off) (BLI_assert((_##stack##_index) + (off) <= _##stack##_num_alloc)) |
| #define | _STACK_SWAP_TOTALLOC(stack_a, stack_b) SWAP(unsigned int, _##stack_a##_num_alloc, _##stack_b##_num_alloc) |
| #define | _STACK_BOUNDSTEST(stack, index) ((void)stack, BLI_assert((unsigned int)(index) < _##stack##_index)) |
| #define | STACK_SIZE(stack) ((void)stack, (_##stack##_index)) |
| #define | STACK_CLEAR(stack) |
| #define | STACK_PUSH(stack, val) ((void)stack, _STACK_SIZETEST(stack, 1), ((stack)[(_##stack##_index)++] = (val))) |
| #define | STACK_PUSH_RET(stack) ((void)stack, _STACK_SIZETEST(stack, 1), ((stack)[(_##stack##_index)++])) |
| #define | STACK_PUSH_RET_PTR(stack) ((void)stack, _STACK_SIZETEST(stack, 1), &((stack)[(_##stack##_index)++])) |
| #define | STACK_POP(stack) ((_##stack##_index) ? ((stack)[--(_##stack##_index)]) : NULL) |
| #define | STACK_POP_PTR(stack) ((_##stack##_index) ? &((stack)[--(_##stack##_index)]) : NULL) |
| #define | STACK_POP_DEFAULT(stack, r) ((_##stack##_index) ? ((stack)[--(_##stack##_index)]) : (r)) |
| #define | STACK_PEEK(stack) (BLI_assert(_##stack##_index), ((stack)[_##stack##_index - 1])) |
| #define | STACK_PEEK_PTR(stack) (BLI_assert(_##stack##_index), &((stack)[_##stack##_index - 1])) |
| #define | STACK_REMOVE(stack, i) |
| #define | STACK_DISCARD(stack, n) |
| #define | STACK_SWAP(stack_a, stack_b) |
Macro's for a simple array based stack
Definition in file BLI_utildefines_stack.h.
| #define _STACK_BOUNDSTEST | ( | stack, | |
| index ) ((void)stack, BLI_assert((unsigned int)(index) < _##stack##_index)) |
Definition at line 32 of file BLI_utildefines_stack.h.
| #define _STACK_SIZETEST | ( | stack, | |
| off ) (BLI_assert((_##stack##_index) + (off) <= _##stack##_num_alloc)) |
Definition at line 21 of file BLI_utildefines_stack.h.
| #define _STACK_SWAP_TOTALLOC | ( | stack_a, | |
| stack_b ) SWAP(unsigned int, _##stack_a##_num_alloc, _##stack_b##_num_alloc) |
Definition at line 23 of file BLI_utildefines_stack.h.
| #define STACK_CLEAR | ( | stack | ) |
Definition at line 36 of file BLI_utildefines_stack.h.
Referenced by bm_face_connect_verts(), EDBM_select_interior_faces(), mesh_calc_path_region_elem(), mesh_calc_path_region_elem(), and remdoubles_createface().
Definition at line 16 of file BLI_utildefines_stack.h.
Referenced by bm_decim_triangulate_end(), bm_edge_info_average_length_fallback(), bm_edgering_pair_subdiv(), bm_face_bisect_verts(), bm_face_connect_verts(), BM_face_split_edgenet(), bm_face_split_edgenet_find_loop_walk(), bm_isect_tri_tri(), BM_mesh_calc_edge_groups(), BM_mesh_calc_edge_groups_as_arrays(), BM_mesh_calc_face_groups(), BM_mesh_intersect(), bmesh_kernel_unglue_region_make_vert_multi(), bmo_bisect_plane_exec(), bmo_offset_edgeloops_exec(), EDBM_select_interior_faces(), initSystem(), mesh_calc_path_region_elem(), mesh_calc_path_region_elem(), MOD_solidify_extrude_modifyMesh(), remdoubles_createface(), TEST(), and blender::ed::object::vgroup_smooth_subset().
| #define STACK_DISCARD | ( | stack, | |
| n ) |
Definition at line 66 of file BLI_utildefines_stack.h.
| #define STACK_INIT | ( | stack, | |
| stack_num ) |
Definition at line 17 of file BLI_utildefines_stack.h.
Referenced by bm_decim_triangulate_end(), bm_edge_info_average_length_fallback(), bm_edgering_pair_subdiv(), bm_face_bisect_verts(), bm_face_connect_verts(), BM_face_split_edgenet(), bm_face_split_edgenet_find_loop_walk(), bm_isect_tri_tri(), BM_mesh_calc_edge_groups(), BM_mesh_calc_edge_groups_as_arrays(), BM_mesh_calc_face_groups(), BM_mesh_intersect(), bmesh_kernel_unglue_region_make_vert_multi(), bmo_bisect_plane_exec(), bmo_offset_edgeloops_exec(), EDBM_select_interior_faces(), initSystem(), mesh_calc_path_region_elem(), mesh_calc_path_region_elem(), MOD_solidify_extrude_modifyMesh(), remdoubles_createface(), TEST(), and blender::ed::object::vgroup_smooth_subset().
| #define STACK_PEEK | ( | stack | ) | (BLI_assert(_##stack##_index), ((stack)[_##stack##_index - 1])) |
look at last item (assumes non-empty stack)
Definition at line 54 of file BLI_utildefines_stack.h.
| #define STACK_PEEK_PTR | ( | stack | ) | (BLI_assert(_##stack##_index), &((stack)[_##stack##_index - 1])) |
Definition at line 55 of file BLI_utildefines_stack.h.
take last item from stack
Definition at line 50 of file BLI_utildefines_stack.h.
Referenced by bm_edgering_pair_subdiv(), BM_face_split_edgenet(), BM_mesh_calc_edge_groups(), BM_mesh_calc_edge_groups_as_arrays(), BM_mesh_calc_face_groups(), bmo_bisect_plane_exec(), bmo_offset_edgeloops_exec(), mesh_calc_path_region_elem(), mesh_calc_path_region_elem(), and TEST().
| #define STACK_POP_DEFAULT | ( | stack, | |
| r ) ((_##stack##_index) ? ((stack)[--(_##stack##_index)]) : (r)) |
Definition at line 52 of file BLI_utildefines_stack.h.
Definition at line 51 of file BLI_utildefines_stack.h.
Referenced by bm_face_split_edgenet_find_loop_walk().
| #define STACK_PUSH | ( | stack, | |
| val ) ((void)stack, _STACK_SIZETEST(stack, 1), ((stack)[(_##stack##_index)++] = (val))) |
add item to stack
Definition at line 43 of file BLI_utildefines_stack.h.
Referenced by bm_decim_triangulate_end(), bm_edge_info_average_length_fallback(), bm_edgering_pair_subdiv(), bm_face_bisect_verts(), BM_face_split_edgenet(), BM_mesh_calc_edge_groups(), BM_mesh_calc_edge_groups_as_arrays(), BM_mesh_calc_face_groups(), bmesh_kernel_unglue_region_make_vert_multi(), bmo_bisect_plane_exec(), bmo_offset_edgeloops_exec(), EDBM_select_interior_faces(), initSystem(), mesh_calc_path_region_elem(), mesh_calc_path_region_elem(), MOD_solidify_extrude_modifyMesh(), remdoubles_createface(), and blender::ed::object::vgroup_smooth_subset().
| #define STACK_PUSH_RET | ( | stack | ) | ((void)stack, _STACK_SIZETEST(stack, 1), ((stack)[(_##stack##_index)++])) |
Definition at line 45 of file BLI_utildefines_stack.h.
Referenced by bm_face_connect_verts(), BM_mesh_calc_edge_groups_as_arrays(), and BM_mesh_intersect().
| #define STACK_PUSH_RET_PTR | ( | stack | ) | ((void)stack, _STACK_SIZETEST(stack, 1), &((stack)[(_##stack##_index)++])) |
Definition at line 47 of file BLI_utildefines_stack.h.
Referenced by bm_face_split_edgenet_find_loop_walk().
| #define STACK_REMOVE | ( | stack, | |
| i ) |
remove any item from the stack, take care, re-orders
Definition at line 57 of file BLI_utildefines_stack.h.
Referenced by bm_edge_info_average_length_fallback(), and bmo_offset_edgeloops_exec().
| #define STACK_SIZE | ( | stack | ) | ((void)stack, (_##stack##_index)) |
Definition at line 35 of file BLI_utildefines_stack.h.
Referenced by bm_decim_triangulate_end(), bm_edge_info_average_length_fallback(), bm_face_bisect_verts(), bm_face_connect_verts(), bm_face_split_edgenet_find_loop_walk(), bm_isect_tri_tri(), BM_mesh_calc_edge_groups(), BM_mesh_calc_edge_groups_as_arrays(), BM_mesh_calc_face_groups(), BM_mesh_intersect(), bmesh_kernel_unglue_region_make_vert_multi(), bmo_offset_edgeloops_exec(), EDBM_select_interior_faces(), initSystem(), mesh_calc_path_region_elem(), mesh_calc_path_region_elem(), MOD_solidify_extrude_modifyMesh(), remdoubles_createface(), and blender::ed::object::vgroup_smooth_subset().
| #define STACK_SWAP | ( | stack_a, | |
| stack_b ) |
Definition at line 83 of file BLI_utildefines_stack.h.
Referenced by mesh_calc_path_region_elem(), and mesh_calc_path_region_elem().