diff options
Diffstat (limited to 'source/blender/editors/mesh')
-rw-r--r-- | source/blender/editors/mesh/bmesh_utils.c | 1 | ||||
-rw-r--r-- | source/blender/editors/mesh/editface.c | 2 | ||||
-rwxr-xr-x | source/blender/editors/mesh/knifetool.c | 22 | ||||
-rw-r--r-- | source/blender/editors/mesh/loopcut.c | 2 | ||||
-rw-r--r-- | source/blender/editors/mesh/mesh_data.c | 2 | ||||
-rw-r--r-- | source/blender/editors/mesh/mesh_intern.h | 77 | ||||
-rw-r--r-- | source/blender/editors/mesh/mesh_navmesh.c | 1 | ||||
-rw-r--r-- | source/blender/editors/mesh/mesh_ops.c | 1 | ||||
-rw-r--r-- | source/blender/editors/mesh/meshtools.c | 2 |
9 files changed, 16 insertions, 94 deletions
diff --git a/source/blender/editors/mesh/bmesh_utils.c b/source/blender/editors/mesh/bmesh_utils.c index f124823b106..29404a6e46a 100644 --- a/source/blender/editors/mesh/bmesh_utils.c +++ b/source/blender/editors/mesh/bmesh_utils.c @@ -27,6 +27,7 @@ #include "MEM_guardedalloc.h" +#include "DNA_mesh_types.h" #include "DNA_object_types.h" #include "DNA_scene_types.h" diff --git a/source/blender/editors/mesh/editface.c b/source/blender/editors/mesh/editface.c index bec1403a8dd..65a34e2d1b3 100644 --- a/source/blender/editors/mesh/editface.c +++ b/source/blender/editors/mesh/editface.c @@ -38,11 +38,11 @@ #include "BLI_blenlib.h" #include "BLI_math.h" #include "BLI_edgehash.h" -#include "BLI_editVert.h" #include "IMB_imbuf_types.h" #include "IMB_imbuf.h" +#include "DNA_mesh_types.h" #include "DNA_meshdata_types.h" #include "DNA_object_types.h" #include "DNA_scene_types.h" diff --git a/source/blender/editors/mesh/knifetool.c b/source/blender/editors/mesh/knifetool.c index 8e56a357487..1b8e90ffce7 100755 --- a/source/blender/editors/mesh/knifetool.c +++ b/source/blender/editors/mesh/knifetool.c @@ -54,9 +54,9 @@ #include "WM_types.h" #include "DNA_scene_types.h" +#include "DNA_mesh_types.h" #include "DNA_object_types.h" #include "BKE_tessmesh.h" -#include "BLI_editVert.h" #include "mesh_intern.h" @@ -1802,8 +1802,8 @@ static void knifenet_fill_faces(knifetool_opdata *kcd) for (i = 0; i < totface; i++) { SmallHash *hash = &shash; - EditFace *efa; - EditVert *eve, *lasteve; + ScanFillFace *efa; + ScanFillVert *eve, *lasteve; int j; float rndscale = FLT_EPSILON * 25; @@ -1818,7 +1818,7 @@ static void knifenet_fill_faces(knifetool_opdata *kcd) for (entry = face_nets[i].first; entry; entry = entry->next) { if (!BLI_smallhash_haskey(hash, (intptr_t)entry->kfe->v1)) { eve = BLI_addfillvert(entry->kfe->v1->v->co); - eve->xs = 0; + eve->poly_nr = 0; rnd_offset_co(eve->co, rndscale); eve->tmp.p = entry->kfe->v1->v; BLI_smallhash_insert(hash, (intptr_t)entry->kfe->v1, eve); @@ -1826,7 +1826,7 @@ static void knifenet_fill_faces(knifetool_opdata *kcd) if (!BLI_smallhash_haskey(hash, (intptr_t)entry->kfe->v2)) { eve = BLI_addfillvert(entry->kfe->v2->v->co); - eve->xs = 0; + eve->poly_nr = 0; rnd_offset_co(eve->co, rndscale); eve->tmp.p = entry->kfe->v2->v; BLI_smallhash_insert(hash, (intptr_t)entry->kfe->v2, eve); @@ -1837,16 +1837,16 @@ static void knifenet_fill_faces(knifetool_opdata *kcd) lasteve = BLI_smallhash_lookup(hash, (intptr_t)entry->kfe->v1); eve = BLI_smallhash_lookup(hash, (intptr_t)entry->kfe->v2); - eve->xs++; - lasteve->xs++; + eve->poly_nr++; + lasteve->poly_nr++; } for (j = 0, entry = face_nets[i].first; entry; entry = entry->next, j++) { lasteve = BLI_smallhash_lookup(hash, (intptr_t)entry->kfe->v1); eve = BLI_smallhash_lookup(hash, (intptr_t)entry->kfe->v2); - if (eve->xs > 1 && lasteve->xs > 1) { - EditEdge *eed; + if (eve->poly_nr > 1 && lasteve->poly_nr > 1) { + ScanFillEdge *eed; eed = BLI_addfilledge(lasteve, eve); if (entry->kfe->oe) eed->f = FILLBOUNDARY; /* mark as original boundary edge */ @@ -1855,9 +1855,9 @@ static void knifenet_fill_faces(knifetool_opdata *kcd) BMO_elem_flag_disable(bm, entry->kfe->e->v2, DEL); } else { - if (lasteve->xs < 2) + if (lasteve->poly_nr < 2) BLI_remlink(&fillvertbase, lasteve); - if (eve->xs < 2) + if (eve->poly_nr < 2) BLI_remlink(&fillvertbase, eve); } } diff --git a/source/blender/editors/mesh/loopcut.c b/source/blender/editors/mesh/loopcut.c index 59861d674f2..794356510aa 100644 --- a/source/blender/editors/mesh/loopcut.c +++ b/source/blender/editors/mesh/loopcut.c @@ -38,6 +38,7 @@ #include "DNA_ID.h" #include "DNA_object_types.h" +#include "DNA_mesh_types.h" #include "DNA_screen_types.h" #include "DNA_scene_types.h" #include "DNA_userdef_types.h" @@ -50,7 +51,6 @@ #include "BLI_blenlib.h" #include "BLI_math.h" #include "BLI_dynstr.h" /*for WM_operator_pystring */ -#include "BLI_editVert.h" #include "BLI_utildefines.h" #include "BKE_blender.h" diff --git a/source/blender/editors/mesh/mesh_data.c b/source/blender/editors/mesh/mesh_data.c index 0d7d6ca8108..c35bf8988b7 100644 --- a/source/blender/editors/mesh/mesh_data.c +++ b/source/blender/editors/mesh/mesh_data.c @@ -36,6 +36,7 @@ #include "MEM_guardedalloc.h" #include "DNA_material_types.h" +#include "DNA_mesh_types.h" #include "DNA_meshdata_types.h" #include "DNA_object_types.h" #include "DNA_scene_types.h" @@ -44,7 +45,6 @@ #include "BLI_utildefines.h" #include "BLI_array.h" #include "BLI_math.h" -#include "BLI_editVert.h" #include "BLI_edgehash.h" #include "BLI_utildefines.h" diff --git a/source/blender/editors/mesh/mesh_intern.h b/source/blender/editors/mesh/mesh_intern.h index 58ad32fad4d..6b0ed5c14d6 100644 --- a/source/blender/editors/mesh/mesh_intern.h +++ b/source/blender/editors/mesh/mesh_intern.h @@ -90,31 +90,6 @@ float labda_PdistVL2Dfl(const float v1[3], const float v2[3], const float v3[3]) /* ******************** editface.c */ -#if 0 /* REMOVE AFTER BMESH MERGE */ - -/* ******************* editmesh.c */ - -extern void free_editvert(EditMesh *em, EditVert *eve); -extern void free_editedge(EditMesh *em, EditEdge *eed); -extern void free_editface(EditMesh *em, EditFace *efa); - -/*frees dst mesh, then copies the contents of - *src (the struct) to dst. */ -void set_editMesh(EditMesh *dst, EditMesh *src); - -extern void free_vertlist(EditMesh *em, ListBase *edve); -extern void free_edgelist(EditMesh *em, ListBase *lb); -extern void free_facelist(EditMesh *em, ListBase *lb); - -extern void remedge(EditMesh *em, EditEdge *eed); - -extern struct EditVert *addvertlist(EditMesh *em, float *vec, struct EditVert *example); -extern struct EditEdge *addedgelist(EditMesh *em, struct EditVert *v1, struct EditVert *v2, struct EditEdge *example); -extern struct EditFace *addfacelist(EditMesh *em, struct EditVert *v1, struct EditVert *v2, struct EditVert *v3, struct EditVert *v4, struct EditFace *example, struct EditFace *exampleEdges); -extern struct EditEdge *findedgelist(EditMesh *em, struct EditVert *v1, struct EditVert *v2); - -#endif - void em_setup_viewcontext(struct bContext *C, struct ViewContext *vc); void MESH_OT_separate(struct wmOperatorType *ot); @@ -137,58 +112,6 @@ void MESH_OT_duplicate(struct wmOperatorType *ot); void MESH_OT_fgon_make(struct wmOperatorType *ot); void MESH_OT_fgon_clear(struct wmOperatorType *ot); -#if 0 /* REMOVE AFTER BMESH MERGE */ - -/* ******************* editmesh_lib.c */ -void EM_stats_update(EditMesh *em); - -extern void EM_fgon_flags(EditMesh *em); -extern void EM_hide_reset(EditMesh *em); - -extern int faceselectedOR(EditFace *efa, int flag); -extern int faceselectedAND(EditFace *efa, int flag); - -void EM_remove_selection(EditMesh *em, void *data, int type); -void EM_clear_flag_all(EditMesh *em, int flag); -void EM_set_flag_all(EditMesh *em, int flag); -void EM_set_flag_all_selectmode(EditMesh *em, int flag); - -void EM_data_interp_from_verts(EditMesh *em, EditVert *v1, EditVert *v2, EditVert *eve, float fac); -void EM_data_interp_from_faces(EditMesh *em, EditFace *efa1, EditFace *efa2, EditFace *efan, int i1, int i2, int i3, int i4); - -int EM_nvertices_selected(EditMesh *em); -int EM_nedges_selected(EditMesh *em); -int EM_nfaces_selected(EditMesh *em); - -float EM_face_perimeter(EditFace *efa); - -void EM_store_selection(EditMesh *em, void *data, int type); - -extern EditFace *exist_face(EditMesh *em, EditVert *v1, EditVert *v2, EditVert *v3, EditVert *v4); -extern void flipface(EditMesh *em, EditFace *efa); // flips for normal direction -extern int compareface(EditFace *vl1, EditFace *vl2); - -/* flag for selection bits, *nor will be filled with normal for extrusion constraint */ -/* return value defines if such normal was set */ -extern short extrudeflag_face_indiv(EditMesh *em, short flag, float *nor); -extern short extrudeflag_verts_indiv(EditMesh *em, short flag, float *nor); -extern short extrudeflag_edges_indiv(EditMesh *em, short flag, float *nor); -extern short extrudeflag_vert(Object *obedit, EditMesh *em, short flag, float *nor, int all); -extern short extrudeflag(Object *obedit, EditMesh *em, short flag, float *nor, int all); - -extern void adduplicateflag(EditMesh *em, int flag); -extern void delfaceflag(EditMesh *em, int flag); - -extern void rotateflag(EditMesh *em, short flag, float *cent, float rotmat[][3]); -extern void translateflag(EditMesh *em, short flag, float *vec); - -extern int convex(float *v1, float *v2, float *v3, float *v4); - -extern struct EditFace *EM_face_from_faces(EditMesh *em, struct EditFace *efa1, - struct EditFace *efa2, int i1, int i2, int i3, int i4); - -#endif - extern int EM_view3d_poll(struct bContext *C); struct wmKeyMap* knifetool_modal_keymap(struct wmKeyConfig *keyconf); diff --git a/source/blender/editors/mesh/mesh_navmesh.c b/source/blender/editors/mesh/mesh_navmesh.c index 99947cb9ae2..cb4f7a37130 100644 --- a/source/blender/editors/mesh/mesh_navmesh.c +++ b/source/blender/editors/mesh/mesh_navmesh.c @@ -48,7 +48,6 @@ #include "BKE_report.h" #include "BKE_tessmesh.h" -#include "BLI_editVert.h" #include "BLI_listbase.h" #include "BLI_utildefines.h" #include "BLI_math_vector.h" diff --git a/source/blender/editors/mesh/mesh_ops.c b/source/blender/editors/mesh/mesh_ops.c index 4bc500fcdab..c3f749b2c45 100644 --- a/source/blender/editors/mesh/mesh_ops.c +++ b/source/blender/editors/mesh/mesh_ops.c @@ -38,7 +38,6 @@ #include "BLI_math.h" #include "BLI_blenlib.h" -#include "BLI_editVert.h" #include "BKE_context.h" diff --git a/source/blender/editors/mesh/meshtools.c b/source/blender/editors/mesh/meshtools.c index 1b5011402fc..bad0718c613 100644 --- a/source/blender/editors/mesh/meshtools.c +++ b/source/blender/editors/mesh/meshtools.c @@ -41,6 +41,7 @@ #include "MEM_guardedalloc.h" +#include "DNA_mesh_types.h" #include "DNA_key_types.h" #include "DNA_material_types.h" #include "DNA_meshdata_types.h" @@ -50,7 +51,6 @@ #include "BLI_math.h" #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLI_editVert.h" #include "BLI_ghash.h" #include "BLI_rand.h" /* for randome face sorting */ #include "BLI_threads.h" |