Cleanup: split normal calculation into it's own file

Normals now includes many functions including normal splitting &
custom normal manipulation split this into it's own file
to centralize related functions.
This commit is contained in:
Campbell Barton 2021-07-01 10:08:47 +10:00
parent 924596abad
commit dba675fb65
5 changed files with 2152 additions and 2109 deletions

View File

@ -299,7 +299,7 @@ void BKE_mesh_recalc_looptri_with_normals(const struct MLoop *mloop,
struct MLoopTri *mlooptri,
const float (*poly_normals)[3]);
/* *** mesh_evaluate.c *** */
/* *** mesh_normals.c *** */
void BKE_mesh_calc_normals_mapping_simple(struct Mesh *me);
void BKE_mesh_calc_normals_mapping(struct MVert *mverts,
@ -494,6 +494,8 @@ void BKE_mesh_calc_normals_split_ex(struct Mesh *mesh,
void BKE_mesh_set_custom_normals(struct Mesh *mesh, float (*r_custom_loopnors)[3]);
void BKE_mesh_set_custom_normals_from_vertices(struct Mesh *mesh, float (*r_custom_vertnors)[3]);
/* *** mesh_evaluate.c *** */
void BKE_mesh_calc_poly_normal(const struct MPoly *mpoly,
const struct MLoop *loopstart,
const struct MVert *mvarray,

View File

@ -190,6 +190,7 @@ set(SRC
intern/mesh_mapping.c
intern/mesh_merge.c
intern/mesh_mirror.c
intern/mesh_normals.c
intern/mesh_remap.c
intern/mesh_remesh_voxel.c
intern/mesh_runtime.c

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -18,6 +18,8 @@
* \ingroup bmesh
*
* BM mesh normal calculation functions.
*
* \see mesh_normals.c for the equivalent #Mesh functionality.
*/
#include "MEM_guardedalloc.h"