Blender Git Loki
Git Commits -> Revision 8a1860b
Revision 8a1860b by Campbell Barton (master) June 14, 2021, 13:01 (GMT) |
BMesh: support face-normal calculation in normal & looptri functions Support calculating face normals when tessellating. When this is done before updating vertex normals it gives ~20% performance improvement. Now vertex normal calculation only needs to perform a single pass on the mesh vertices when called after tessellation. Extended versions of normal & looptri update functions have been added: - BM_mesh_calc_tessellation_ex - BM_mesh_normals_update_ex Most callers don't need to be aware of this detail by using: - BKE_editmesh_looptri_and_normals_calc - BKE_editmesh_looptri_and_normals_calc_with_partial - EDBM_update also takes advantage of this, where calling EDBM_update with calc_looptri & calc_normals enabled uses the faster normal updating logic. |
Commit Details:
Full Hash: 8a1860bd9aecddf611b64e3e842bdc8c76f15cc6
Parent Commit: 6bef255
Lines Changed: +286, -63
14 Modified Paths:
/source/blender/blenkernel/BKE_editmesh.h (+10, -0) (Diff)
/source/blender/blenkernel/intern/editmesh.c (+54, -6) (Diff)
/source/blender/bmesh/intern/bmesh_mesh_normals.c (+32, -9) (Diff)
/source/blender/bmesh/intern/bmesh_mesh_normals.h (+12, -0) (Diff)
/source/blender/bmesh/intern/bmesh_mesh_tessellate.c (+133, -28) (Diff)
/source/blender/bmesh/intern/bmesh_mesh_tessellate.h (+16, -0) (Diff)
/source/blender/editors/include/ED_mesh.h (+3, -0) (Diff)
/source/blender/editors/mesh/editmesh_utils.c (+19, -5) (Diff)
/source/blender/editors/object/object_edit.c (+1, -3) (Diff)
/source/blender/editors/object/object_hook.c (+1, -2) (Diff)
/source/blender/editors/object/object_relations.c (+1, -2) (Diff)
/source/blender/editors/transform/transform_convert_mesh.c (+2, -4) (Diff)
/source/blender/editors/transform/transform_convert_mesh_skin.c (+1, -2) (Diff)
/source/blender/makesrna/intern/rna_object.c (+1, -2) (Diff)
/source/blender/blenkernel/intern/editmesh.c (+54, -6) (Diff)
/source/blender/bmesh/intern/bmesh_mesh_normals.c (+32, -9) (Diff)
/source/blender/bmesh/intern/bmesh_mesh_normals.h (+12, -0) (Diff)
/source/blender/bmesh/intern/bmesh_mesh_tessellate.c (+133, -28) (Diff)
/source/blender/bmesh/intern/bmesh_mesh_tessellate.h (+16, -0) (Diff)
/source/blender/editors/include/ED_mesh.h (+3, -0) (Diff)
/source/blender/editors/mesh/editmesh_utils.c (+19, -5) (Diff)
/source/blender/editors/object/object_edit.c (+1, -3) (Diff)
/source/blender/editors/object/object_hook.c (+1, -2) (Diff)
/source/blender/editors/object/object_relations.c (+1, -2) (Diff)
/source/blender/editors/transform/transform_convert_mesh.c (+2, -4) (Diff)
/source/blender/editors/transform/transform_convert_mesh_skin.c (+1, -2) (Diff)
/source/blender/makesrna/intern/rna_object.c (+1, -2) (Diff)