Mesh: Avoid unnecessary normal calculation and dirty tags
This is mostly a cleanup to avoid hardcoding the eager calculation of normals it isn't necessary, by reducing calls to `BKE_mesh_calc_normals` and by removing calls to `BKE_mesh_normals_tag_dirty` when the mesh is newly created and already has dirty normals anyway. This reduces boilerplate code and makes the "dirty by default" state more clear. Any regressions from this commit should be easy to fix, though the lazy calculation is solid enough that none are expected.
This commit is contained in:
@@ -530,8 +530,6 @@ static Mesh *modifyMesh(ModifierData *md, const ModifierEvalContext *ctx, Mesh *
|
||||
MEM_SAFE_FREE(vert_part_index);
|
||||
MEM_SAFE_FREE(vert_part_value);
|
||||
|
||||
BKE_mesh_normals_tag_dirty(result);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user