diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-06-14 15:56:01 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-06-14 15:56:01 +0300 |
commit | 8083527f90d1556f576cf102d4143749677c45e0 (patch) | |
tree | 347f2be8a4aaa305a8e6a1125dbf5f7fb3174b13 /source/blender/editors/include | |
parent | 1d2eb461b528cc309ad6d2fa94ce1e910e93d8be (diff) |
Edit Mesh: use params arg for update function, add calc_normals arg
Rename function EDBM_update_generic to EDBM_update, use a parameters
argument for better readability.
Also add calc_normals argument, which will have benefits when
calculating normals and tessellation together is optimized.
Diffstat (limited to 'source/blender/editors/include')
-rw-r--r-- | source/blender/editors/include/ED_mesh.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/source/blender/editors/include/ED_mesh.h b/source/blender/editors/include/ED_mesh.h index b8e9f6e8871..b76c35c7d7a 100644 --- a/source/blender/editors/include/ED_mesh.h +++ b/source/blender/editors/include/ED_mesh.h @@ -103,7 +103,14 @@ bool EDBM_vert_color_check(struct BMEditMesh *em); bool EDBM_mesh_hide(struct BMEditMesh *em, bool swap); bool EDBM_mesh_reveal(struct BMEditMesh *em, bool select); -void EDBM_update_generic(struct Mesh *me, const bool do_tessellation, const bool is_destructive); +struct EDBMUpdate_Params { + uint calc_looptri : 1; + uint calc_normals : 1; + uint is_destructive : 1; +}; + +void EDBM_update(struct Mesh *me, const struct EDBMUpdate_Params *params); +void EDBM_update_extern(struct Mesh *me, const bool do_tessellation, const bool is_destructive); struct UvElementMap *BM_uv_element_map_create(struct BMesh *bm, const struct Scene *scene, |