From 5ddf971057c1abb5e009b8294cd04fee341ab104 Mon Sep 17 00:00:00 2001 From: nesme Date: Wed, 6 Sep 2017 16:16:47 +0200 Subject: [PATCH] Merge pull request #364 from hugtalbot/fix_warnings_201708 [all] Fix warnings and strange double incrementation on iterator (cherry picked from commit 893c3d36f9530ac15b72a2ceb50bdd8aca4c8cac) --- SofaKernel/framework/sofa/helper/LCPcalc.cpp | 2 +- .../VolumetricRendering/OglTetrahedralModel.inl | 4 ++-- .../plugins/VolumetricRendering/OglVolumetricModel.cpp | 10 +++++----- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/SofaKernel/framework/sofa/helper/LCPcalc.cpp b/SofaKernel/framework/sofa/helper/LCPcalc.cpp index fcf355dc9a8..4b4a916cd7a 100644 --- a/SofaKernel/framework/sofa/helper/LCPcalc.cpp +++ b/SofaKernel/framework/sofa/helper/LCPcalc.cpp @@ -1003,8 +1003,8 @@ void projection(LCP &fineLevel, LCP &coarseLevel, int nbContactsCoarse, const st /// output=> change value of F in fineLevel void prolongation(LCP &fineLevel, LCP &coarseLevel, const std::vector &projectionTable, const std::vector &projectionConstraints, std::vector & projectionValues, std::vector &contact_is_projected, bool verbose) - { + SOFA_UNUSED(verbose) ; int numContactsFine = fineLevel.getDim()/3; diff --git a/applications/plugins/VolumetricRendering/OglTetrahedralModel.inl b/applications/plugins/VolumetricRendering/OglTetrahedralModel.inl index fa6bb36bff7..faeb3a975b3 100644 --- a/applications/plugins/VolumetricRendering/OglTetrahedralModel.inl +++ b/applications/plugins/VolumetricRendering/OglTetrahedralModel.inl @@ -42,11 +42,11 @@ template OglTetrahedralModel::OglTetrahedralModel() : m_topology(NULL) , m_positions(initData(&m_positions, "position", "Vertices coordinates")) + , depthTest(initData(&depthTest, (bool)false, "depthTest", "Set Depth Test")) + , blending(initData(&blending, (bool)false, "blending", "Set Blending")) , modified(false) , lastMeshRev(-1) , useTopology(false) - , depthTest(initData(&depthTest, (bool)false, "depthTest", "Set Depth Test")) - , blending(initData(&blending, (bool)false, "blending", "Set Blending")) { } diff --git a/applications/plugins/VolumetricRendering/OglVolumetricModel.cpp b/applications/plugins/VolumetricRendering/OglVolumetricModel.cpp index 08ea8103fc2..cb6e29dbbaf 100644 --- a/applications/plugins/VolumetricRendering/OglVolumetricModel.cpp +++ b/applications/plugins/VolumetricRendering/OglVolumetricModel.cpp @@ -48,15 +48,15 @@ int OglVolumetricModelClass = sofa::core::RegisterObject("Volumetric model for O OglVolumetricModel::OglVolumetricModel() - : b_modified(false) - , b_useTopology(false) - , b_tboCreated(false) + : d_tetrahedra(initData(&d_tetrahedra, "tetrahedra", "Tetrahedra to draw")) + , d_hexahedra(initData(&d_hexahedra, "hexahedra", "Hexahedra to draw")) , d_volumeScale(initData(&d_volumeScale, (float)1.0, "volumeScale", "Scale for each volumetric primitive")) , d_depthTest(initData(&d_depthTest, (bool)false, "depthTest", "Set Depth Test")) , d_blending(initData(&d_blending, (bool)false, "blending", "Set Blending")) , d_defaultColor(initData(&d_defaultColor, defaulttype::Vec4f(), "defaultColor", "Color for each volume (if the attribute a_vertexColor is not detected)")) - , d_tetrahedra(initData(&d_tetrahedra, "tetrahedra", "Tetrahedra to draw")) - , d_hexahedra(initData(&d_hexahedra, "hexahedra", "Hexahedra to draw")) + , b_modified(false) + , b_useTopology(false) + , b_tboCreated(false) { addAlias(&d_defaultColor, "color"); }