From 3dbdbdde7dd4f58b5d398aeb2d48e60f0eb2b7dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20M=C3=B6bius?= Date: Wed, 6 Feb 2019 11:06:35 +0100 Subject: [PATCH] Silence some VS2017 warnings due to double float conversion --- src/OpenMesh/Core/Mesh/PolyMeshT.cc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/OpenMesh/Core/Mesh/PolyMeshT.cc b/src/OpenMesh/Core/Mesh/PolyMeshT.cc index 78e6b004..0d69daff 100644 --- a/src/OpenMesh/Core/Mesh/PolyMeshT.cc +++ b/src/OpenMesh/Core/Mesh/PolyMeshT.cc @@ -161,7 +161,7 @@ PolyMeshT::calc_face_normal_impl(FaceHandle, PointIsNot3DTag) const assert(false); Normal normal; - vectorize(normal,0); + vectorize(normal,static_cast(0.0)); return normal; } @@ -229,7 +229,7 @@ PolyMeshT::calc_face_normal_impl(const Point&, const Point&, const Point assert(false); Normal normal; - vectorize(normal,0); + vectorize(normal,static_cast(0.0)); return normal; } @@ -241,7 +241,7 @@ PolyMeshT:: calc_face_centroid(FaceHandle _fh) const { Point _pt; - vectorize(_pt, 0); + vectorize(_pt, static_cast(0.0)); Scalar valence = 0.0; for (ConstFaceVertexIter cfv_it = this->cfv_iter(_fh); cfv_it.is_valid(); ++cfv_it, valence += 1.0) { @@ -404,7 +404,7 @@ template void PolyMeshT:: calc_vertex_normal_fast(VertexHandle _vh, Normal& _n) const { - vectorize(_n, 0.0); + vectorize(_n, static_cast(0.0) ); for (ConstVertexFaceIter vf_it = this->cvf_iter(_vh); vf_it.is_valid(); ++vf_it) _n += this->normal(*vf_it); } @@ -414,7 +414,7 @@ template void PolyMeshT:: calc_vertex_normal_correct(VertexHandle _vh, Normal& _n) const { - vectorize(_n, 0.0); + vectorize(_n, static_cast(0.0) ); ConstVertexIHalfedgeIter cvih_it = this->cvih_iter(_vh); if (! cvih_it.is_valid() ) {//don't crash on isolated vertices