|
Blender V4.3
|
Go to the source code of this file.
Classes | |
| struct | ScanFillContext |
| struct | ScanFillVert |
| struct | ScanFillEdge |
| struct | ScanFillFace |
Macros | |
| #define | BLI_SCANFILL_ARENA_SIZE MEM_SIZE_OPTIMAL(1 << 14) |
| #define | SF_POLY_UNSET ((unsigned short)-1) |
Typedefs | |
| typedef struct ScanFillContext | ScanFillContext |
| typedef struct ScanFillVert | ScanFillVert |
| typedef struct ScanFillEdge | ScanFillEdge |
| typedef struct ScanFillFace | ScanFillFace |
Enumerations | |
| enum | { BLI_SCANFILL_CALC_REMOVE_DOUBLES = (1 << 1) , BLI_SCANFILL_CALC_POLYS = (1 << 2) , BLI_SCANFILL_CALC_HOLES = (1 << 3) , BLI_SCANFILL_CALC_LOOSE = (1 << 4) } |
Functions | |
| struct ScanFillVert * | BLI_scanfill_vert_add (ScanFillContext *sf_ctx, const float vec[3]) |
| struct ScanFillEdge * | BLI_scanfill_edge_add (ScanFillContext *sf_ctx, struct ScanFillVert *v1, struct ScanFillVert *v2) |
| void | BLI_scanfill_begin (ScanFillContext *sf_ctx) |
| unsigned int | BLI_scanfill_calc (ScanFillContext *sf_ctx, int flag) |
| unsigned int | BLI_scanfill_calc_ex (ScanFillContext *sf_ctx, int flag, const float nor_proj[3]) |
| void | BLI_scanfill_end (ScanFillContext *sf_ctx) |
| void | BLI_scanfill_begin_arena (ScanFillContext *sf_ctx, struct MemArena *arena) |
| void | BLI_scanfill_end_arena (ScanFillContext *sf_ctx, struct MemArena *arena) |
| bool | BLI_scanfill_calc_self_isect (ScanFillContext *sf_ctx, ListBase *remvertbase, ListBase *remedgebase) |
| #define BLI_SCANFILL_ARENA_SIZE MEM_SIZE_OPTIMAL(1 << 14) |
Definition at line 30 of file BLI_scanfill.h.
Referenced by BKE_displist_fill(), BKE_maskrasterize_handle_init(), and BLI_scanfill_begin().
| #define SF_POLY_UNSET ((unsigned short)-1) |
Definition at line 37 of file BLI_scanfill.h.
Referenced by BLI_scanfill_begin(), BLI_scanfill_begin_arena(), BLI_scanfill_calc_ex(), and BLI_scanfill_calc_self_isect().
| typedef struct ScanFillContext ScanFillContext |
| typedef struct ScanFillEdge ScanFillEdge |
| typedef struct ScanFillFace ScanFillFace |
| typedef struct ScanFillVert ScanFillVert |
| anonymous enum |
| Enumerator | |
|---|---|
| BLI_SCANFILL_CALC_REMOVE_DOUBLES | |
| BLI_SCANFILL_CALC_POLYS | |
| BLI_SCANFILL_CALC_HOLES | |
| BLI_SCANFILL_CALC_LOOSE | |
Definition at line 85 of file BLI_scanfill.h.
| void BLI_scanfill_begin | ( | ScanFillContext * | sf_ctx | ) |
Definition at line 791 of file scanfill.c.
References ScanFillContext::arena, BLI_memarena_new(), BLI_SCANFILL_ARENA_SIZE, ScanFillContext::poly_nr, and SF_POLY_UNSET.
Referenced by bmo_triangle_fill_exec().
| void BLI_scanfill_begin_arena | ( | ScanFillContext * | sf_ctx, |
| struct MemArena * | arena ) |
Definition at line 798 of file scanfill.c.
References ScanFillContext::arena, ScanFillContext::poly_nr, and SF_POLY_UNSET.
Referenced by BKE_displist_fill(), and BKE_maskrasterize_handle_init().
| unsigned int BLI_scanfill_calc | ( | ScanFillContext * | sf_ctx, |
| int | flag ) |
Definition at line 1152 of file scanfill.c.
References BLI_scanfill_calc_ex(), flag, and NULL.
| unsigned int BLI_scanfill_calc_ex | ( | ScanFillContext * | sf_ctx, |
| int | flag, | ||
| const float | nor_proj[3] ) |
Definition at line 825 of file scanfill.c.
References add_newell_cross_v3_v3v3(), axis_dominant_v3_to_m3_negate(), BLI_assert, BLI_listbase_clear(), BLI_listbase_is_empty(), BLI_movelisttolist(), BLI_remlink(), BLI_SCANFILL_CALC_HOLES, BLI_SCANFILL_CALC_LOOSE, BLI_SCANFILL_CALC_POLYS, ScanFillVert::co, compare_v3v3(), copy_v3_v3(), ScanFillVert::edge_count, PolyFill::edges, PolyFill::f, ScanFillVert::f, fill_target_map_recursive(), ScanFillContext::filledgebase, ScanFillContext::fillvertbase, ListBase::first, flag, ListBase::last, len_squared_v3(), LIKELY, PolyFill::max_xy, MEM_freeN(), MEM_mallocN, mergepolysSimp(), PolyFill::min_xy, mul_v2_m3v3(), ScanFillEdge::next, ScanFillVert::next, normalize_v3(), NULL, pf, ScanFillContext::poly_nr, ScanFillEdge::poly_nr, ScanFillVert::poly_nr, ScanFillEdge::prev, printf, range_vn_u(), scanfill(), SF_EPSILON, SF_POLY_NEW, SF_POLY_UNSET, SF_POLY_VALID, SF_VERT_AVAILABLE, splitlist(), testvertexnearedge(), UNLIKELY, ScanFillEdge::v1, ScanFillEdge::v2, PolyFill::verts, ScanFillVert::xy, and zero_v3().
Referenced by BKE_displist_fill(), BKE_maskrasterize_handle_init(), BLI_scanfill_calc(), and bmo_triangle_fill_exec().
| bool BLI_scanfill_calc_self_isect | ( | ScanFillContext * | sf_ctx, |
| ListBase * | remvertbase, | ||
| ListBase * | remedgebase ) |
Call before scan-fill to remove self intersections.
Definition at line 364 of file scanfill_utils.c.
References BLI_addtail(), BLI_assert, BLI_remlink(), E_ISDELETE, PolyInfo::edge_first, PolyInfo::edge_last, ScanFillContext::filledgebase, ScanFillContext::fillvertbase, ListBase::first, ListBase::last, MEM_callocN, MEM_freeN(), ScanFillEdge::next, ScanFillVert::next, NULL, ScanFillContext::poly_nr, ScanFillEdge::poly_nr, ScanFillVert::poly_nr, scanfill_preprocess_self_isect(), SF_POLY_UNSET, UNLIKELY, ScanFillEdge::user_flag, ScanFillVert::user_flag, ScanFillEdge::v1, and ScanFillEdge::v2.
Referenced by BKE_maskrasterize_handle_init().
| struct ScanFillEdge * BLI_scanfill_edge_add | ( | ScanFillContext * | sf_ctx, |
| struct ScanFillVert * | v1, | ||
| struct ScanFillVert * | v2 ) |
Definition at line 117 of file scanfill.c.
References ScanFillContext::arena, BLI_addtail(), BLI_memarena_alloc(), ScanFillEdge::c, ScanFillEdge::f, ScanFillContext::filledgebase, ScanFillContext::poly_nr, ScanFillEdge::poly_nr, SF_EDGE_NEW, ScanFillEdge::tmp, ScanFillEdge::user_flag, ScanFillEdge::v1, ScanFillEdge::v2, and v2.
Referenced by BKE_displist_fill(), BKE_maskrasterize_handle_init(), bmo_triangle_fill_exec(), scanfill(), scanfill_preprocess_self_isect(), and testvertexnearedge().
| void BLI_scanfill_end | ( | ScanFillContext * | sf_ctx | ) |
Definition at line 805 of file scanfill.c.
References ScanFillContext::arena, BLI_listbase_clear(), BLI_memarena_free(), ScanFillContext::filledgebase, ScanFillContext::fillfacebase, ScanFillContext::fillvertbase, and NULL.
Referenced by bmo_triangle_fill_exec().
| void BLI_scanfill_end_arena | ( | ScanFillContext * | sf_ctx, |
| struct MemArena * | arena ) |
Definition at line 815 of file scanfill.c.
References ScanFillContext::arena, BLI_assert, BLI_listbase_clear(), BLI_memarena_clear(), ScanFillContext::filledgebase, ScanFillContext::fillfacebase, and ScanFillContext::fillvertbase.
Referenced by BKE_displist_fill(), and BKE_maskrasterize_handle_init().
| struct ScanFillVert * BLI_scanfill_vert_add | ( | ScanFillContext * | sf_ctx, |
| const float | vec[3] ) |
Definition at line 95 of file scanfill.c.
References ScanFillContext::arena, BLI_addtail(), BLI_memarena_alloc(), ScanFillVert::co, copy_v3_v3(), ScanFillVert::edge_count, ScanFillVert::f, ScanFillContext::fillvertbase, ScanFillVert::keyindex, NULL, ScanFillVert::p, ScanFillContext::poly_nr, ScanFillVert::poly_nr, SF_VERT_NEW, ScanFillVert::tmp, ScanFillVert::user_flag, ScanFillVert::xy, and zero_v2().
Referenced by BKE_displist_fill(), bmo_triangle_fill_exec(), scanfill_preprocess_self_isect(), and scanfill_vert_add_v2_with_depth().