From d1aacfa2ab27f86b65cd2e32148406c8db0cef49 Mon Sep 17 00:00:00 2001 From: Paolo Cignoni Date: Fri, 6 Apr 2018 13:27:26 +0200 Subject: [PATCH] Harmless warnings --- src/common/meshlabdocumentbundler.cpp | 1 - src/common/ml_shared_data_context.cpp | 8 ++++---- src/common/pluginmanager.cpp | 6 +++--- 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/src/common/meshlabdocumentbundler.cpp b/src/common/meshlabdocumentbundler.cpp index 4e45133d5..c8960ef36 100644 --- a/src/common/meshlabdocumentbundler.cpp +++ b/src/common/meshlabdocumentbundler.cpp @@ -29,7 +29,6 @@ bool MeshDocumentFromBundler(MeshDocument &md, QString filename_out,QString imag // QStringList image_filenames_q; - QSize size; for(unsigned int i = 0; i < image_filenames.size(); ++i) { QImageReader sizeImg(QString::fromStdString(image_filenames[i])); diff --git a/src/common/ml_shared_data_context.cpp b/src/common/ml_shared_data_context.cpp index 2016274e1..8b5d27849 100644 --- a/src/common/ml_shared_data_context.cpp +++ b/src/common/ml_shared_data_context.cpp @@ -5,7 +5,7 @@ #include "meshmodel.h" MLSceneGLSharedDataContext::MLSceneGLSharedDataContext(MeshDocument& md,vcg::QtThreadSafeMemoryInfo& gpumeminfo,bool highprecision,size_t perbatchtriangles, size_t minfacespersmoothrendering) - :QGLWidget(),_md(md),_gpumeminfo(gpumeminfo),_perbatchtriangles(perbatchtriangles),_highprecision(highprecision), _minfacessmoothrendering(minfacespersmoothrendering) + :QGLWidget(),_md(md),_gpumeminfo(gpumeminfo),_perbatchtriangles(perbatchtriangles), _minfacessmoothrendering(minfacespersmoothrendering),_highprecision(highprecision) { if (md.size() != 0) throw MLException(QString("MLSceneGLSharedDataContext: MeshDocument is not empty when MLSceneGLSharedDataContext is constructed.")); @@ -401,13 +401,13 @@ void MLSceneGLSharedDataContext::updateGPUMemInfo() glGetIntegerv(GPU_MEMORY_INFO_TOTAL_AVAILABLE_MEMORY_NVX, &allmem); GLint currentallocated = 0; glGetIntegerv(GPU_MEMORY_INFO_CURRENT_AVAILABLE_VIDMEM_NVX, ¤tallocated); - GLenum errorNV = glGetError(); // purge errors + /*GLenum errorNV =*/ glGetError(); // purge errors GLint ATI_vbo[4] = { 0, 0, 0, 0 }; glGetIntegerv(VBO_FREE_MEMORY_ATI, ATI_vbo); GLint ATI_tex[4] = { 0, 0, 0, 0 }; glGetIntegerv(TEXTURE_FREE_MEMORY_ATI, ATI_tex); - GLenum errorATI = glGetError(); // purge errors + /*GLenum errorATI =*/ glGetError(); // purge errors doneCurrentGLContext(ctx); emit currentAllocatedGPUMem((int)allmem, (int)currentallocated, (int)ATI_tex[0], (int)ATI_vbo[0]); @@ -654,7 +654,7 @@ void MLPoliciesStandAloneFunctions::suggestedDefaultPerViewRenderingData(MeshMod dt.set(MLRenderingData::PR_POINTS,false); tmpatts.reset(); tmpatts[MLRenderingData::ATT_NAMES::ATT_VERTPOSITION] = true; - tmpatts[MLRenderingData::ATT_NAMES::ATT_VERTNORMAL] = (meshmodel->cm.FN() > minpolnumpersmoothshading); + tmpatts[MLRenderingData::ATT_NAMES::ATT_VERTNORMAL] = (size_t(meshmodel->cm.FN()) > minpolnumpersmoothshading); tmpatts[MLRenderingData::ATT_NAMES::ATT_FACENORMAL] = !(tmpatts[MLRenderingData::ATT_NAMES::ATT_VERTNORMAL]); tmpatts[MLRenderingData::ATT_NAMES::ATT_VERTCOLOR] = true; if (meshmodel != NULL) diff --git a/src/common/pluginmanager.cpp b/src/common/pluginmanager.cpp index 4fbe1e1a8..7e7370a74 100644 --- a/src/common/pluginmanager.cpp +++ b/src/common/pluginmanager.cpp @@ -142,11 +142,11 @@ void PluginManager::loadPlugins(RichParameterSet& defaultGlobal) iFilter->initGlobalParameterSet(filterAction, defaultGlobal); if(iFilter->getClass(filterAction)==MeshFilterInterface::Generic) throw MLException("Missing class for " +fileName+filterAction->text()); - if(iFilter->getRequirements(filterAction) == MeshModel::MM_UNKNOWN) + if(iFilter->getRequirements(filterAction) == int(MeshModel::MM_UNKNOWN)) throw MLException("Missing requirements for " +fileName+filterAction->text()); - if(iFilter->getPreConditions(filterAction) == MeshModel::MM_UNKNOWN) + if(iFilter->getPreConditions(filterAction) == int(MeshModel::MM_UNKNOWN)) throw MLException("Missing preconditions for "+fileName+filterAction->text()); - if(iFilter->postCondition(filterAction) == MeshModel::MM_UNKNOWN ) + if(iFilter->postCondition(filterAction) == int(MeshModel::MM_UNKNOWN )) throw MLException("Missing postcondition for "+fileName+filterAction->text()); if(iFilter->filterArity(filterAction) == MeshFilterInterface::UNKNOWN_ARITY ) throw MLException("Missing Arity for " +fileName+filterAction->text());