1

OpenMesh has the calc_dihedral_angle() function to calculate the dihedral angle between two faces. Is there a signed/directed equivalent of this function? Halfedges of faces are directed, thus normals of faces are well defined. It is thus meaningful to talk about the convexity.

Consider the following simple case, of only two connected faces. Starting from a zero dihedral (in-plane neighboring faces) one can rotate one of the faces around the common edge in either direction. In one case, the surface will be convex, in the other case, it will be concave. calc_dihedral_angle() does not differentiate between the two. I am looking for a function which takes this directionality into account and gives either a positive or a negative dihedral, depending on the convexity.

Botond
  • 2,640
  • 6
  • 28
  • 44
  • 2
    Use the dot product of the normals to decide if the angle is >90 or <90, but in terms of sign convention it makes no sense unless you have a rotation axis & direction specified. – JAlex Nov 06 '20 at 18:26
  • I realized that `calc_dihedral_angle()` already does that. I agree that the choice of sign is unspecified, but doesn't matter as long as it's consistent and allows to distinguish between the two directions. – Botond Nov 09 '20 at 14:28

1 Answers1

1

Actually that is exactly what calc_dihedral_angle() does.

Botond
  • 2,640
  • 6
  • 28
  • 44