Cleanup: split ED_mesh_mirror_*_table into multiple functions

Spatial & topology mirror table each used a single function
taking a char as an identifier.

Split these into begin/end/lookup functions.
This commit is contained in:
2020-04-03 21:47:56 +11:00
parent b5253159b6
commit 7ec59cc7b7
10 changed files with 129 additions and 111 deletions

View File

@@ -450,9 +450,19 @@ int join_mesh_exec(struct bContext *C, struct wmOperator *op);
int join_mesh_shapes_exec(struct bContext *C, struct wmOperator *op);
/* mirror lookup api */
int ED_mesh_mirror_spatial_table(
struct Object *ob, struct BMEditMesh *em, struct Mesh *me_eval, const float co[3], char mode);
int ED_mesh_mirror_topo_table(struct Object *ob, struct Mesh *me_eval, char mode);
/* Spatial Mirror */
void ED_mesh_mirror_spatial_table_begin(struct Object *ob,
struct BMEditMesh *em,
struct Mesh *me_eval);
void ED_mesh_mirror_spatial_table_end(struct Object *ob);
int ED_mesh_mirror_spatial_table_lookup(struct Object *ob,
struct BMEditMesh *em,
struct Mesh *me_eval,
const float co[3]);
/* Topology Mirror */
void ED_mesh_mirror_topo_table_begin(struct Object *ob, struct Mesh *me_eval);
void ED_mesh_mirror_topo_table_end(struct Object *ob);
/* retrieves mirrored cache vert, or NULL if there isn't one.
* note: calling this without ensuring the mirror cache state