in calc_normal for EdgeHandle average incident face normals instead of incident vertex normals

This commit is contained in:
Max Lyon
2022-11-23 11:37:36 +01:00
parent 3f328cdf0d
commit 121ff40b19
2 changed files with 25 additions and 9 deletions

View File

@@ -456,13 +456,7 @@ public:
}
/// calculated and returns the average of the two vertex normals
Normal calc_normal(EdgeHandle _eh) const
{
HalfedgeHandle _heh = this->halfedge_handle(_eh, 0);
VertexHandle vh0 = this->from_vertex_handle(_heh);
VertexHandle vh1 = this->to_vertex_handle(_heh);
return 0.5 * (this->calc_normal(vh0) + this->calc_normal(vh1));
}
Normal calc_normal(EdgeHandle _eh) const;
/** defines a consistent representation of a sector geometry:
the halfedge _in_heh defines the sector orientation