Unittests now use the Point/Normal types related to the mesh type, instead of relying on them being OpenMesh vectors.

This commit is contained in:
Christian Mattes
2018-04-12 15:18:11 +02:00
parent 377562d11a
commit 5a2f426d8c
4 changed files with 25 additions and 24 deletions

View File

@@ -164,7 +164,8 @@ TEST_F(OpenMeshOthers, CalcDihedralAngre ) {
EXPECT_EQ( 0.0 , mesh_.calc_dihedral_angle(eh) ) << "Wrong Dihedral angle!" << std::endl;
// Modify point
Mesh::Point tmp = ( Mesh::Point(0.0, 0.0, -1.0) + Mesh::Point(1.0, 1.0, -1.0) ) * static_cast<Mesh::Point::value_type>(0.5);
Mesh::Point tmp = ( Mesh::Point(0.0, 0.0, -1.0) + Mesh::Point(1.0, 1.0, -1.0) )
* static_cast<typename OpenMesh::vector_traits<typename Mesh::Point>::value_type>(0.5);
mesh_.point(vhandle[2]) = tmp;
double difference = fabs( 1.36944 - mesh_.calc_dihedral_angle(eh) );