diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt
index b896aa6b5..a45dfd98f 100644
--- a/src/common/CMakeLists.txt
+++ b/src/common/CMakeLists.txt
@@ -15,6 +15,7 @@ set(SOURCES
filter_parameter/rich_parameter_list.cpp
filter_parameter/value.cpp
interfaces/plugin_interface.cpp
+ interfaces/filter_plugin_interface.cpp
GLExtensionsManager.cpp
GLLogStream.cpp
filterscript.cpp
@@ -35,6 +36,7 @@ set(HEADERS
filter_parameter/value.h
interfaces/mainwindow_interface.h
interfaces/plugin_interface.h
+ interfaces/filter_plugin_interface.h
interfaces/io_plugin_interface.h
GLExtensionsManager.h
GLLogStream.h
diff --git a/src/common/common.pro b/src/common/common.pro
index 3e5ed260e..7835dddb2 100644
--- a/src/common/common.pro
+++ b/src/common/common.pro
@@ -48,6 +48,7 @@ HEADERS += \
filterscript.h \
GLLogStream.h \
interfaces.h \
+ interfaces/filter_plugin_interface.h \
interfaces/io_plugin_interface.h \
interfaces/mainwindow_interface.h \
interfaces/plugin_interface.h \
@@ -69,6 +70,7 @@ SOURCES += \
interfaces.cpp \
filterscript.cpp \
GLLogStream.cpp \
+ interfaces/filter_plugin_interface.cpp \
interfaces/plugin_interface.cpp \
meshmodel.cpp \
pluginmanager.cpp \
diff --git a/src/common/interfaces.cpp b/src/common/interfaces.cpp
index c73952de5..faf9d662c 100644
--- a/src/common/interfaces.cpp
+++ b/src/common/interfaces.cpp
@@ -1,71 +1,3 @@
#include "interfaces.h"
-bool MeshFilterInterface::isFilterApplicable(const QAction* act, const MeshModel& m, QStringList &MissingItems) const
-{
- int preMask = getPreConditions(act);
- MissingItems.clear();
- if (preMask == MeshModel::MM_NONE) // no precondition specified.
- return true;
-
- if (preMask & MeshModel::MM_VERTCOLOR && !m.hasDataMask(MeshModel::MM_VERTCOLOR))
- MissingItems.push_back("Vertex Color");
-
- if (preMask & MeshModel::MM_FACECOLOR && !m.hasDataMask(MeshModel::MM_FACECOLOR))
- MissingItems.push_back("Face Color");
-
- if (preMask & MeshModel::MM_VERTQUALITY && !m.hasDataMask(MeshModel::MM_VERTQUALITY))
- MissingItems.push_back("Vertex Quality");
-
- if (preMask & MeshModel::MM_FACEQUALITY && !m.hasDataMask(MeshModel::MM_FACEQUALITY))
- MissingItems.push_back("Face Quality");
-
- if (preMask & MeshModel::MM_WEDGTEXCOORD && !m.hasDataMask(MeshModel::MM_WEDGTEXCOORD))
- MissingItems.push_back("Per Wedge Texture Coords");
-
- if (preMask & MeshModel::MM_VERTTEXCOORD && !m.hasDataMask(MeshModel::MM_VERTTEXCOORD))
- MissingItems.push_back("Per Vertex Texture Coords");
-
- if (preMask & MeshModel::MM_VERTRADIUS && !m.hasDataMask(MeshModel::MM_VERTRADIUS))
- MissingItems.push_back("Vertex Radius");
-
- if (preMask & MeshModel::MM_CAMERA && !m.hasDataMask(MeshModel::MM_CAMERA))
- MissingItems.push_back("Camera");
-
- if (preMask & MeshModel::MM_FACENUMBER && (m.cm.fn==0))
- MissingItems.push_back("Any Faces");
-
-
- return MissingItems.isEmpty();
-}
-
-int MeshFilterInterface::previewOnCreatedAttributes(const QAction* act, const MeshModel& mm ) const
-{
- int changedIfCalled = postCondition(act);
- int createdIfCalled = MeshModel::MM_NONE;
- if ((changedIfCalled & MeshModel::MM_VERTCOLOR) && !mm.hasDataMask(MeshModel::MM_VERTCOLOR))
- createdIfCalled = createdIfCalled | MeshModel::MM_VERTCOLOR;
-
- if ((changedIfCalled & MeshModel::MM_FACECOLOR) && !mm.hasDataMask(MeshModel::MM_FACECOLOR))
- createdIfCalled = createdIfCalled | MeshModel::MM_FACECOLOR;
-
- if ((changedIfCalled & MeshModel::MM_VERTQUALITY) && !mm.hasDataMask(MeshModel::MM_VERTQUALITY))
- createdIfCalled = createdIfCalled | MeshModel::MM_VERTQUALITY;
-
- if ((changedIfCalled & MeshModel::MM_FACEQUALITY) && !mm.hasDataMask(MeshModel::MM_FACEQUALITY))
- createdIfCalled = createdIfCalled | MeshModel::MM_FACEQUALITY;
-
- if ((changedIfCalled & MeshModel::MM_WEDGTEXCOORD) && !mm.hasDataMask(MeshModel::MM_WEDGTEXCOORD))
- createdIfCalled = createdIfCalled | MeshModel::MM_WEDGTEXCOORD;
-
- if ((changedIfCalled & MeshModel::MM_VERTTEXCOORD) && !mm.hasDataMask(MeshModel::MM_VERTTEXCOORD))
- createdIfCalled = createdIfCalled | MeshModel::MM_VERTTEXCOORD;
-
- if ((changedIfCalled & MeshModel::MM_VERTRADIUS) && !mm.hasDataMask(MeshModel::MM_VERTRADIUS))
- createdIfCalled = createdIfCalled | MeshModel::MM_VERTRADIUS;
-
- if ((getClass(act) == MeshFilterInterface::MeshCreation) && (mm.cm.vn == 0))
- createdIfCalled = createdIfCalled | MeshModel::MM_VERTCOORD;
-
- return createdIfCalled;
-}
diff --git a/src/common/interfaces.h b/src/common/interfaces.h
index 3ff978cca..be5251036 100644
--- a/src/common/interfaces.h
+++ b/src/common/interfaces.h
@@ -52,211 +52,6 @@ class GLAreaReg;
class MeshModel;
-
-/**
-\brief The MeshFilterInterface class provide the interface of the filter plugins.
-
-*/
-class MeshFilterInterface : public PluginInterface
-{
-public:
- /** The FilterClass enum represents the set of keywords that must be used to categorize a filter.
- Each filter can belong to one or more filtering class, or-ed together.
- */
- enum FilterClass
- {
- Generic = 0x00000, /*!< Should be avoided if possible. */ //
- Selection = 0x00001, /*!< select or de-select something, basic operation on selections (like deleting)*/
- Cleaning = 0x00002, /*!< Filters that can be used to clean meshes (duplicated vertices etc)*/
- Remeshing = 0x00004, /*!< Simplification, Refinement, Reconstruction and mesh optimization*/
- FaceColoring = 0x00008,
- VertexColoring = 0x00010,
- MeshColoring = 0x00020,
- MeshCreation = 0x00040,
- Smoothing = 0x00080, /*!< Stuff that does not change the topology, but just the vertex positions*/
- Quality = 0x00100,
- Layer = 0x00200, /*!< Layers, attributes */
- RasterLayer = 0x00400, /*!< Raster Layers, attributes */
- Normal = 0x00800, /*!< Normal, Curvature, orientation (rotations and transformations fall here)*/
- Sampling = 0x01000,
- Texture = 0x02000,
- RangeMap = 0x04000, /*!< filters specific for range map processing*/
- PointSet = 0x08000,
- Measure = 0x10000, /*!< Filters that compute measures and information on meshes.*/
- Polygonal = 0x20000, /*!< Filters that works on polygonal and quad meshes.*/
- Camera = 0x40000 /*!< Filters that works on shot of mesh and raster.*/
- };
-
-
-
- MeshFilterInterface() : PluginInterface(), glContext(NULL)
- {
- }
- virtual ~MeshFilterInterface() {}
-
-
- /** The very short string (a few words) describing each filtering action
- // This string is used also to define the menu entry
- */
- virtual QString filterName(FilterIDType) const = 0;
-
- /** The long, formatted string describing each filtering action.
- // This string is printed in the top of the parameter window
- // so it should be at least one or two paragraphs long. The more the better.
- // you can use simple html formatting tags (like "
" "" and "") to improve readability.
- // This string is used in the 'About plugin' dialog and by meshlabserver to create the filter list wiki page and the doxygen documentation of the filters.
- // Here is the place where you should put you bibliographic references in a form like this:
-
- See:
- Luiz Velho, Denis Zorin
- "4-8 Subdivision"
- CAGD, volume 18, Issue 5, Pages 397-427.
-
- e.g. italic for authors, bold for title (quoted) and plain for bib ref.
- */
- virtual QString filterInfo(FilterIDType filter) const = 0;
-
- /** The FilterClass describes in which generic class of filters it fits.
- // This choice affect the submenu in which each filter will be placed
- // For example filters that perform an action only on the selection will be placed in the Selection Class
- */
- virtual FilterClass getClass(const QAction *) const { return MeshFilterInterface::Generic; }
-
- /**
- The filters can have some additional requirements on the mesh capabiliteis.
- // For example if a filters requires Face-Face Adjacency you should re-implement
- // this function making it returns MeshModel::MM_FACEFACETOPO.
- // The framework will ensure that the mesh has the requirements satisfied before invoking the applyFilter function
- //
- // Furthermore, requirements are checked just before the invocation of a filter. If your filter
- // outputs a never used before mesh property (e.g. face colors), it will be allocated by a call
- // to MeshModel::updateDataMask(...)
- */
- virtual int getRequirements(const QAction *) { return MeshModel::MM_NONE; }
-
- /** The FilterPrecondition mask is used to explicitate what kind of data a filter really needs to be applied.
- // For example algorithms that compute per face quality have as precondition the existence of faces
- // (but quality per face is not a precondition, because quality per face is created by these algorithms)
- // on the other hand an algorithm that deletes faces according to the stored quality has both FaceQuality
- // and Face as precondition.
- // These conditions do NOT include computed properties like borderFlags, manifoldness or watertightness.
- // They are also used to grayout menus un-appliable entries.
- */
- virtual int getPreConditions(const QAction *) const { return MeshModel::MM_NONE; }
-
- /** Function used by the framework to get info about the mesh properties changed by the filter.
- // It is widely used by the meshlab's preview system.
- //TO BE REPLACED WITH = 0
- */
- virtual int postCondition(const QAction*) const { return MeshModel::MM_ALL; }
-
- /** \brief applies the selected filter with the already stabilished parameters
- * This function is called by the framework after getting values for the parameters specified in the \ref InitParameterSet
- * NO GUI interaction should be done here. No dialog asking, no messagebox errors.
- * Think that his function will also be called by the commandline framework.
- * If you want report errors, use the \ref errorMsg() string. It will displayed in case of filters returning false.
- * When implementing your applyFilter, you should use the cb function to report to the framework the current state of the processing.
- * During your (long) processing you should call from time to time cb(perc,descriptiveString), where perc is an int (0..100)
- * saying what you are doing and at what point of the computation you currently are.
- * \sa errorMsg
- * \sa initParameterSet
- */
- virtual bool applyFilter(const QAction* filter, MeshDocument &md, const RichParameterList & par, vcg::CallBackPos *cb) = 0;
-
- /** \brief tests if a filter is applicable to a mesh.
- This function is a handy wrapper used by the framework for the \a getPreConditions callback;
- For instance a colorize by quality filter cannot be applied to a mesh without per-vertex-quality.
- On failure (returning false) the function fills the MissingItems list with strings describing the missing items.
- */
- bool isFilterApplicable(const QAction *act, const MeshModel& m, QStringList &MissingItems) const;
-
-
- enum FILTER_ARITY { NONE = 0, SINGLE_MESH = 1, FIXED = 2, VARIABLE = 3, UNKNOWN_ARITY = 4 };
-
- /** \brief this function informs the MeshLab core on how many meshes the filter will work on.
- Valid value:
- - SINGLE_MESH: the filter works just on the current mesh
- - FIXED: the number (and the names) of the meshes involved in the filter computation is determined by the parameters selected in the filter's parameters form
- - VARIABLE: the filter works on a not predetermined number of meshes. The meshes involved are typically selected by the user checking on the correspondent layer on the layer dialog
- */
- virtual FILTER_ARITY filterArity(const QAction *act) const = 0;
-
- // This function is called to initialized the list of parameters.
- // it is always called. If a filter does not need parameter it leave it empty and the framework
- // will not create a dialog (unless for previewing)
- virtual void initParameterList(const QAction *, MeshModel &/*m*/, RichParameterList & /*par*/) {}
- virtual void initParameterList(const QAction *filter, MeshDocument &md, RichParameterList &par)
- {
- initParameterList(filter, *(md.mm()), par);
- }
-
- /** \brief is invoked by the framework when the applyFilter fails to give some info to the user about the filter failure
- * Filters \b must never use QMessageBox for reporting errors.
- * Failing filters should put some meaningful information inside the errorMessage string and return false with the \ref applyFilter
- */
- const QString &errorMsg() const { return this->errorMessage; }
- virtual QString filterInfo(const QAction *a) const { return this->filterInfo(ID(a)); }
- virtual QString filterName(const QAction *a) const { return this->filterName(ID(a)); }
- virtual QString filterScriptFunctionName(FilterIDType /*filterID*/) { return ""; }
-
- virtual FilterIDType ID(const QAction *a) const
- {
- QString aa=a->text();
- foreach(FilterIDType tt, types())
- if (a->text() == this->filterName(tt)) return tt;
- aa.replace("&","");
- foreach(FilterIDType tt, types())
- if (aa == this->filterName(tt)) return tt;
-
- qDebug("unable to find the id corresponding to action '%s'", qUtf8Printable(a->text()));
- assert(0);
- return -1;
- }
-
- virtual QAction *AC(FilterIDType filterID)
- {
- QString idName = this->filterName(filterID);
- return AC(idName);
- }
-
- virtual QAction *AC(const QString& idName)
- {
- QString i=idName;
- for(QAction *tt : actionList)
- if (idName == tt->text()) return tt;
- i.replace("&","");
- for(QAction *tt : actionList)
- if (i == tt->text()) return tt;
-
- qDebug("unable to find the action corresponding to action '%s'", qUtf8Printable(idName));
- assert(0);
- return 0;
- }
-
- virtual QList actions() const { return actionList; }
- virtual QList types() const { return typeList; }
-
- /** Generate the mask of attributes would be created IF the MeshFilterInterface filt would has been called on MeshModel mm
- BE CAREFUL! this function does NOT change in anyway the state of the MeshModel!!!! **/
- int previewOnCreatedAttributes(const QAction* act, const MeshModel& mm) const;
- QString generatedScriptCode;
-
- MLPluginGLContext* glContext;
-protected:
- // Each plugins exposes a set of filtering possibilities.
- // Each filtering procedure corresponds to a single QAction with a corresponding FilterIDType id.
- //
-
- // The list of actions exported by the plugin. Each actions strictly corresponds to
- QList actionList;
-
- QList typeList;
-
- // this string is used to pass back to the framework error messages in case of failure of a filter apply.
- QString errorMessage;
-};
-
-
/**
Used to customized the rendering process.
Rendering plugins are now responsible of the rendering of the whole MeshDocument and not only of a single MeshModel.
@@ -490,14 +285,11 @@ public:
#define MESHLAB_PLUGIN_IID_EXPORTER(x) Q_PLUGIN_METADATA(IID x)
#define MESHLAB_PLUGIN_NAME_EXPORTER(x)
-#define MESH_FILTER_INTERFACE_IID "vcg.meshlab.MeshFilterInterface/1.0"
-#define MESHLAB_FILTER_INTERFACE_IID "vcg.meshlab.MeshLabFilterInterface/1.0"
#define MESH_RENDER_INTERFACE_IID "vcg.meshlab.MeshRenderInterface/1.0"
#define MESH_DECORATE_INTERFACE_IID "vcg.meshlab.MeshDecorateInterface/1.0"
#define MESH_EDIT_INTERFACE_IID "vcg.meshlab.MeshEditInterface/1.0"
#define MESH_EDIT_INTERFACE_FACTORY_IID "vcg.meshlab.MeshEditInterfaceFactory/1.0"
-Q_DECLARE_INTERFACE(MeshFilterInterface, MESH_FILTER_INTERFACE_IID)
Q_DECLARE_INTERFACE(MeshRenderInterface, MESH_RENDER_INTERFACE_IID)
Q_DECLARE_INTERFACE(MeshDecorateInterface, MESH_DECORATE_INTERFACE_IID)
Q_DECLARE_INTERFACE(MeshEditInterface, MESH_EDIT_INTERFACE_IID)
diff --git a/src/common/interfaces/filter_plugin_interface.cpp b/src/common/interfaces/filter_plugin_interface.cpp
new file mode 100644
index 000000000..581dcdf18
--- /dev/null
+++ b/src/common/interfaces/filter_plugin_interface.cpp
@@ -0,0 +1,71 @@
+#include "filter_plugin_interface.h"
+
+bool FilterPluginInterface::isFilterApplicable(const QAction* act, const MeshModel& m, QStringList &MissingItems) const
+{
+ int preMask = getPreConditions(act);
+ MissingItems.clear();
+
+ if (preMask == MeshModel::MM_NONE) // no precondition specified.
+ return true;
+
+ if (preMask & MeshModel::MM_VERTCOLOR && !m.hasDataMask(MeshModel::MM_VERTCOLOR))
+ MissingItems.push_back("Vertex Color");
+
+ if (preMask & MeshModel::MM_FACECOLOR && !m.hasDataMask(MeshModel::MM_FACECOLOR))
+ MissingItems.push_back("Face Color");
+
+ if (preMask & MeshModel::MM_VERTQUALITY && !m.hasDataMask(MeshModel::MM_VERTQUALITY))
+ MissingItems.push_back("Vertex Quality");
+
+ if (preMask & MeshModel::MM_FACEQUALITY && !m.hasDataMask(MeshModel::MM_FACEQUALITY))
+ MissingItems.push_back("Face Quality");
+
+ if (preMask & MeshModel::MM_WEDGTEXCOORD && !m.hasDataMask(MeshModel::MM_WEDGTEXCOORD))
+ MissingItems.push_back("Per Wedge Texture Coords");
+
+ if (preMask & MeshModel::MM_VERTTEXCOORD && !m.hasDataMask(MeshModel::MM_VERTTEXCOORD))
+ MissingItems.push_back("Per Vertex Texture Coords");
+
+ if (preMask & MeshModel::MM_VERTRADIUS && !m.hasDataMask(MeshModel::MM_VERTRADIUS))
+ MissingItems.push_back("Vertex Radius");
+
+ if (preMask & MeshModel::MM_CAMERA && !m.hasDataMask(MeshModel::MM_CAMERA))
+ MissingItems.push_back("Camera");
+
+ if (preMask & MeshModel::MM_FACENUMBER && (m.cm.fn==0))
+ MissingItems.push_back("Any Faces");
+
+
+ return MissingItems.isEmpty();
+}
+
+int FilterPluginInterface::previewOnCreatedAttributes(const QAction* act, const MeshModel& mm ) const
+{
+ int changedIfCalled = postCondition(act);
+ int createdIfCalled = MeshModel::MM_NONE;
+ if ((changedIfCalled & MeshModel::MM_VERTCOLOR) && !mm.hasDataMask(MeshModel::MM_VERTCOLOR))
+ createdIfCalled = createdIfCalled | MeshModel::MM_VERTCOLOR;
+
+ if ((changedIfCalled & MeshModel::MM_FACECOLOR) && !mm.hasDataMask(MeshModel::MM_FACECOLOR))
+ createdIfCalled = createdIfCalled | MeshModel::MM_FACECOLOR;
+
+ if ((changedIfCalled & MeshModel::MM_VERTQUALITY) && !mm.hasDataMask(MeshModel::MM_VERTQUALITY))
+ createdIfCalled = createdIfCalled | MeshModel::MM_VERTQUALITY;
+
+ if ((changedIfCalled & MeshModel::MM_FACEQUALITY) && !mm.hasDataMask(MeshModel::MM_FACEQUALITY))
+ createdIfCalled = createdIfCalled | MeshModel::MM_FACEQUALITY;
+
+ if ((changedIfCalled & MeshModel::MM_WEDGTEXCOORD) && !mm.hasDataMask(MeshModel::MM_WEDGTEXCOORD))
+ createdIfCalled = createdIfCalled | MeshModel::MM_WEDGTEXCOORD;
+
+ if ((changedIfCalled & MeshModel::MM_VERTTEXCOORD) && !mm.hasDataMask(MeshModel::MM_VERTTEXCOORD))
+ createdIfCalled = createdIfCalled | MeshModel::MM_VERTTEXCOORD;
+
+ if ((changedIfCalled & MeshModel::MM_VERTRADIUS) && !mm.hasDataMask(MeshModel::MM_VERTRADIUS))
+ createdIfCalled = createdIfCalled | MeshModel::MM_VERTRADIUS;
+
+ if ((getClass(act) == FilterPluginInterface::MeshCreation) && (mm.cm.vn == 0))
+ createdIfCalled = createdIfCalled | MeshModel::MM_VERTCOORD;
+
+ return createdIfCalled;
+}
diff --git a/src/common/interfaces/filter_plugin_interface.h b/src/common/interfaces/filter_plugin_interface.h
new file mode 100644
index 000000000..d022bb78a
--- /dev/null
+++ b/src/common/interfaces/filter_plugin_interface.h
@@ -0,0 +1,239 @@
+/****************************************************************************
+* MeshLab o o *
+* A versatile mesh processing toolbox o o *
+* _ O _ *
+* Copyright(C) 2005-2020 \/)\/ *
+* Visual Computing Lab /\/| *
+* ISTI - Italian National Research Council | *
+* \ *
+* All rights reserved. *
+* *
+* This program is free software; you can redistribute it and/or modify *
+* it under the terms of the GNU General Public License as published by *
+* the Free Software Foundation; either version 2 of the License, or *
+* (at your option) any later version. *
+* *
+* This program is distributed in the hope that it will be useful, *
+* but WITHOUT ANY WARRANTY; without even the implied warranty of *
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
+* GNU General Public License (http://www.gnu.org/licenses/gpl.txt) *
+* for more details. *
+* *
+****************************************************************************/
+
+#ifndef MESHLAB_FILTER_PLUGIN_INTERFACE_H
+#define MESHLAB_FILTER_PLUGIN_INTERFACE_H
+
+#include "plugin_interface.h"
+#include "../meshmodel.h"
+
+/**
+\brief The MeshFilterInterface class provide the interface of the filter plugins.
+
+*/
+class FilterPluginInterface : public PluginInterface
+{
+public:
+ /** The FilterClass enum represents the set of keywords that must be used to categorize a filter.
+ Each filter can belong to one or more filtering class, or-ed together.
+ */
+ enum FilterClass
+ {
+ Generic = 0x00000, /*!< Should be avoided if possible. */ //
+ Selection = 0x00001, /*!< select or de-select something, basic operation on selections (like deleting)*/
+ Cleaning = 0x00002, /*!< Filters that can be used to clean meshes (duplicated vertices etc)*/
+ Remeshing = 0x00004, /*!< Simplification, Refinement, Reconstruction and mesh optimization*/
+ FaceColoring = 0x00008,
+ VertexColoring = 0x00010,
+ MeshColoring = 0x00020,
+ MeshCreation = 0x00040,
+ Smoothing = 0x00080, /*!< Stuff that does not change the topology, but just the vertex positions*/
+ Quality = 0x00100,
+ Layer = 0x00200, /*!< Layers, attributes */
+ RasterLayer = 0x00400, /*!< Raster Layers, attributes */
+ Normal = 0x00800, /*!< Normal, Curvature, orientation (rotations and transformations fall here)*/
+ Sampling = 0x01000,
+ Texture = 0x02000,
+ RangeMap = 0x04000, /*!< filters specific for range map processing*/
+ PointSet = 0x08000,
+ Measure = 0x10000, /*!< Filters that compute measures and information on meshes.*/
+ Polygonal = 0x20000, /*!< Filters that works on polygonal and quad meshes.*/
+ Camera = 0x40000 /*!< Filters that works on shot of mesh and raster.*/
+ };
+
+
+
+ FilterPluginInterface() : PluginInterface(), glContext(NULL)
+ {
+ }
+ virtual ~FilterPluginInterface() {}
+
+
+ /** The very short string (a few words) describing each filtering action
+ // This string is used also to define the menu entry
+ */
+ virtual QString filterName(FilterIDType) const = 0;
+
+ /** The long, formatted string describing each filtering action.
+ // This string is printed in the top of the parameter window
+ // so it should be at least one or two paragraphs long. The more the better.
+ // you can use simple html formatting tags (like "
" "" and "") to improve readability.
+ // This string is used in the 'About plugin' dialog and by meshlabserver to create the filter list wiki page and the doxygen documentation of the filters.
+ // Here is the place where you should put you bibliographic references in a form like this:
+
+ See:
+ Luiz Velho, Denis Zorin
+ "4-8 Subdivision"
+ CAGD, volume 18, Issue 5, Pages 397-427.
+
+ e.g. italic for authors, bold for title (quoted) and plain for bib ref.
+ */
+ virtual QString filterInfo(FilterIDType filter) const = 0;
+
+ /** The FilterClass describes in which generic class of filters it fits.
+ // This choice affect the submenu in which each filter will be placed
+ // For example filters that perform an action only on the selection will be placed in the Selection Class
+ */
+ virtual FilterClass getClass(const QAction *) const { return FilterPluginInterface::Generic; }
+
+ /**
+ The filters can have some additional requirements on the mesh capabiliteis.
+ // For example if a filters requires Face-Face Adjacency you should re-implement
+ // this function making it returns MeshModel::MM_FACEFACETOPO.
+ // The framework will ensure that the mesh has the requirements satisfied before invoking the applyFilter function
+ //
+ // Furthermore, requirements are checked just before the invocation of a filter. If your filter
+ // outputs a never used before mesh property (e.g. face colors), it will be allocated by a call
+ // to MeshModel::updateDataMask(...)
+ */
+ virtual int getRequirements(const QAction *) { return MeshModel::MM_NONE; }
+
+ /** The FilterPrecondition mask is used to explicitate what kind of data a filter really needs to be applied.
+ // For example algorithms that compute per face quality have as precondition the existence of faces
+ // (but quality per face is not a precondition, because quality per face is created by these algorithms)
+ // on the other hand an algorithm that deletes faces according to the stored quality has both FaceQuality
+ // and Face as precondition.
+ // These conditions do NOT include computed properties like borderFlags, manifoldness or watertightness.
+ // They are also used to grayout menus un-appliable entries.
+ */
+ virtual int getPreConditions(const QAction *) const { return MeshModel::MM_NONE; }
+
+ /** Function used by the framework to get info about the mesh properties changed by the filter.
+ // It is widely used by the meshlab's preview system.
+ //TO BE REPLACED WITH = 0
+ */
+ virtual int postCondition(const QAction*) const { return MeshModel::MM_ALL; }
+
+ /** \brief applies the selected filter with the already stabilished parameters
+ * This function is called by the framework after getting values for the parameters specified in the \ref InitParameterSet
+ * NO GUI interaction should be done here. No dialog asking, no messagebox errors.
+ * Think that his function will also be called by the commandline framework.
+ * If you want report errors, use the \ref errorMsg() string. It will displayed in case of filters returning false.
+ * When implementing your applyFilter, you should use the cb function to report to the framework the current state of the processing.
+ * During your (long) processing you should call from time to time cb(perc,descriptiveString), where perc is an int (0..100)
+ * saying what you are doing and at what point of the computation you currently are.
+ * \sa errorMsg
+ * \sa initParameterSet
+ */
+ virtual bool applyFilter(const QAction* filter, MeshDocument &md, const RichParameterList & par, vcg::CallBackPos *cb) = 0;
+
+ /** \brief tests if a filter is applicable to a mesh.
+ This function is a handy wrapper used by the framework for the \a getPreConditions callback;
+ For instance a colorize by quality filter cannot be applied to a mesh without per-vertex-quality.
+ On failure (returning false) the function fills the MissingItems list with strings describing the missing items.
+ */
+ bool isFilterApplicable(const QAction *act, const MeshModel& m, QStringList &MissingItems) const;
+
+
+ enum FILTER_ARITY { NONE = 0, SINGLE_MESH = 1, FIXED = 2, VARIABLE = 3, UNKNOWN_ARITY = 4 };
+
+ /** \brief this function informs the MeshLab core on how many meshes the filter will work on.
+ Valid value:
+ - SINGLE_MESH: the filter works just on the current mesh
+ - FIXED: the number (and the names) of the meshes involved in the filter computation is determined by the parameters selected in the filter's parameters form
+ - VARIABLE: the filter works on a not predetermined number of meshes. The meshes involved are typically selected by the user checking on the correspondent layer on the layer dialog
+ */
+ virtual FILTER_ARITY filterArity(const QAction *act) const = 0;
+
+ // This function is called to initialized the list of parameters.
+ // it is always called. If a filter does not need parameter it leave it empty and the framework
+ // will not create a dialog (unless for previewing)
+ virtual void initParameterList(const QAction *, MeshModel &/*m*/, RichParameterList & /*par*/) {}
+ virtual void initParameterList(const QAction *filter, MeshDocument &md, RichParameterList &par)
+ {
+ initParameterList(filter, *(md.mm()), par);
+ }
+
+ /** \brief is invoked by the framework when the applyFilter fails to give some info to the user about the filter failure
+ * Filters \b must never use QMessageBox for reporting errors.
+ * Failing filters should put some meaningful information inside the errorMessage string and return false with the \ref applyFilter
+ */
+ const QString &errorMsg() const { return this->errorMessage; }
+ virtual QString filterInfo(const QAction *a) const { return this->filterInfo(ID(a)); }
+ virtual QString filterName(const QAction *a) const { return this->filterName(ID(a)); }
+ virtual QString filterScriptFunctionName(FilterIDType /*filterID*/) { return ""; }
+
+ virtual FilterIDType ID(const QAction *a) const
+ {
+ QString aa=a->text();
+ foreach(FilterIDType tt, types())
+ if (a->text() == this->filterName(tt)) return tt;
+ aa.replace("&","");
+ foreach(FilterIDType tt, types())
+ if (aa == this->filterName(tt)) return tt;
+
+ qDebug("unable to find the id corresponding to action '%s'", qUtf8Printable(a->text()));
+ assert(0);
+ return -1;
+ }
+
+ virtual QAction *AC(FilterIDType filterID)
+ {
+ QString idName = this->filterName(filterID);
+ return AC(idName);
+ }
+
+ virtual QAction *AC(const QString& idName)
+ {
+ QString i=idName;
+ for(QAction *tt : actionList)
+ if (idName == tt->text()) return tt;
+ i.replace("&","");
+ for(QAction *tt : actionList)
+ if (i == tt->text()) return tt;
+
+ qDebug("unable to find the action corresponding to action '%s'", qUtf8Printable(idName));
+ assert(0);
+ return 0;
+ }
+
+ virtual QList actions() const { return actionList; }
+ virtual QList types() const { return typeList; }
+
+ /** Generate the mask of attributes would be created IF the MeshFilterInterface filt would has been called on MeshModel mm
+ BE CAREFUL! this function does NOT change in anyway the state of the MeshModel!!!! **/
+ int previewOnCreatedAttributes(const QAction* act, const MeshModel& mm) const;
+ QString generatedScriptCode;
+
+ MLPluginGLContext* glContext;
+protected:
+ // Each plugins exposes a set of filtering possibilities.
+ // Each filtering procedure corresponds to a single QAction with a corresponding FilterIDType id.
+ //
+
+ // The list of actions exported by the plugin. Each actions strictly corresponds to
+ QList actionList;
+
+ QList typeList;
+
+ // this string is used to pass back to the framework error messages in case of failure of a filter apply.
+ QString errorMessage;
+};
+
+#define MESHLAB_PLUGIN_IID_EXPORTER(x) Q_PLUGIN_METADATA(IID x)
+#define MESHLAB_PLUGIN_NAME_EXPORTER(x)
+
+#define FILTER_PLUGIN_INTERFACE_IID "vcg.meshlab.FilterPluginInterface/1.0"
+Q_DECLARE_INTERFACE(FilterPluginInterface, FILTER_PLUGIN_INTERFACE_IID)
+
+#endif // MESHLAB_FILTER_PLUGIN_INTERFACE_H
diff --git a/src/common/interfaces/io_plugin_interface.h b/src/common/interfaces/io_plugin_interface.h
index 770415f6a..c64fb966b 100644
--- a/src/common/interfaces/io_plugin_interface.h
+++ b/src/common/interfaces/io_plugin_interface.h
@@ -106,7 +106,7 @@ public:
#define MESHLAB_PLUGIN_IID_EXPORTER(x) Q_PLUGIN_METADATA(IID x)
#define MESHLAB_PLUGIN_NAME_EXPORTER(x)
-#define MESH_IO_INTERFACE_IID "vcg.meshlab.IOPluginInterface/1.0"
-Q_DECLARE_INTERFACE(IOPluginInterface, MESH_IO_INTERFACE_IID)
+#define IO_PLUGIN_INTERFACE_IID "vcg.meshlab.IOPluginInterface/1.0"
+Q_DECLARE_INTERFACE(IOPluginInterface, IO_PLUGIN_INTERFACE_IID)
#endif // MESHLAB_IO_PLUGIN_INTERFACE_H
diff --git a/src/common/pluginmanager.cpp b/src/common/pluginmanager.cpp
index 441f71d83..1384a5d38 100644
--- a/src/common/pluginmanager.cpp
+++ b/src/common/pluginmanager.cpp
@@ -84,7 +84,7 @@ void PluginManager::loadPlugins(RichParameterList& defaultGlobal, const QDir& pl
{
pluginsLoaded.push_back(fileName);
PluginInterface *iCommon = nullptr;
- MeshFilterInterface *iFilter = qobject_cast(plugin);
+ FilterPluginInterface *iFilter = qobject_cast(plugin);
if (iFilter)
{
iCommon = iFilter;
@@ -95,7 +95,7 @@ void PluginManager::loadPlugins(RichParameterList& defaultGlobal, const QDir& pl
actionFilterMap.insert(filterAction->text(), filterAction);
stringFilterMap.insert(filterAction->text(), iFilter);
iFilter->initGlobalParameterSet(filterAction, defaultGlobal);
- if(iFilter->getClass(filterAction)==MeshFilterInterface::Generic)
+ if(iFilter->getClass(filterAction)==FilterPluginInterface::Generic)
throw MLException("Missing class for " +fileName+filterAction->text());
if(iFilter->getRequirements(filterAction) == int(MeshModel::MM_UNKNOWN))
throw MLException("Missing requirements for " +fileName+filterAction->text());
@@ -103,7 +103,7 @@ void PluginManager::loadPlugins(RichParameterList& defaultGlobal, const QDir& pl
throw MLException("Missing preconditions for "+fileName+filterAction->text());
if(iFilter->postCondition(filterAction) == int(MeshModel::MM_UNKNOWN ))
throw MLException("Missing postcondition for "+fileName+filterAction->text());
- if(iFilter->filterArity(filterAction) == MeshFilterInterface::UNKNOWN_ARITY )
+ if(iFilter->filterArity(filterAction) == FilterPluginInterface::UNKNOWN_ARITY )
throw MLException("Missing Arity for " +fileName+filterAction->text());
}
}
diff --git a/src/common/pluginmanager.h b/src/common/pluginmanager.h
index 6f54774c9..ae70da109 100644
--- a/src/common/pluginmanager.h
+++ b/src/common/pluginmanager.h
@@ -25,6 +25,7 @@
#define PLUGINMANAGER_H
#include "interfaces.h"
+#include "interfaces/filter_plugin_interface.h"
#include "interfaces/io_plugin_interface.h"
//#include "scriptsyntax.h"
@@ -45,7 +46,7 @@ public:
QString pluginsCode() const;
int numberIOPlugins() const;
- inline QVector& meshFilterPlugins() {return meshFilterPlug;}
+ inline QVector& meshFilterPlugins() {return meshFilterPlug;}
inline QVector& meshRenderPlugins() {return meshRenderPlug;}
inline QVector& meshDecoratePlugins() {return meshDecoratePlug;}
inline QVector& meshEditFactoryPlugins() {return meshEditInterfacePlug;}
@@ -59,14 +60,14 @@ public:
QMap actionFilterMap;
- QMap stringFilterMap;
+ QMap stringFilterMap;
QMap allKnowInputFormats;
QMap allKnowOutputFormats;
QStringList inpFilters;
QStringList outFilters;
QVector meshIOPlug;
- QVector meshFilterPlug;
+ QVector meshFilterPlug;
QVector meshRenderPlug;
QVector meshDecoratePlug;
QVector meshEditInterfacePlug;
diff --git a/src/meshlab/filterScriptDialog.cpp b/src/meshlab/filterScriptDialog.cpp
index 0bf4fc5c9..5c177692f 100644
--- a/src/meshlab/filterScriptDialog.cpp
+++ b/src/meshlab/filterScriptDialog.cpp
@@ -210,7 +210,7 @@ void FilterScriptDialog::editOldParameters( const int row )
//get a pointer to this action and filter from the main window so we can get the
//description of the parameters from the filter
QAction *action = mainWindow->pluginManager().actionFilterMap[actionName];
- MeshFilterInterface *iFilter = qobject_cast(action->parent());
+ FilterPluginInterface *iFilter = qobject_cast(action->parent());
if(NULL == iFilter){
qDebug() << "null filter";
diff --git a/src/meshlab/mainwindow_Init.cpp b/src/meshlab/mainwindow_Init.cpp
index 3e6063c3c..27b323686 100644
--- a/src/meshlab/mainwindow_Init.cpp
+++ b/src/meshlab/mainwindow_Init.cpp
@@ -500,7 +500,7 @@ void MainWindow::createToolBars()
filterToolBar = addToolBar(tr("Filter"));
filterToolBar->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::Preferred);
- foreach(MeshFilterInterface *iFilter, PM.meshFilterPlugins())
+ foreach(FilterPluginInterface *iFilter, PM.meshFilterPlugins())
{
foreach(QAction* filterAction, iFilter->actions())
{
@@ -717,10 +717,10 @@ void MainWindow::fillFilterMenu()
filterMenu->addMenu(filterMenuCamera);
- QMap::iterator msi;
+ QMap::iterator msi;
for (msi = PM.stringFilterMap.begin(); msi != PM.stringFilterMap.end(); ++msi)
{
- MeshFilterInterface * iFilter = msi.value();
+ FilterPluginInterface * iFilter = msi.value();
QAction *filterAction = iFilter->AC((msi.key()));
QString tooltip = iFilter->filterInfo(filterAction) + "
" + getDecoratedFileName(filterAction->data().toString());
filterAction->setToolTip(tooltip);
@@ -728,79 +728,79 @@ void MainWindow::fillFilterMenu()
connect(filterAction, SIGNAL(triggered()), this, SLOT(startFilter()));
int filterClass = iFilter->getClass(filterAction);
- if (filterClass & MeshFilterInterface::FaceColoring)
+ if (filterClass & FilterPluginInterface::FaceColoring)
{
filterMenuColorize->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::VertexColoring)
+ if (filterClass & FilterPluginInterface::VertexColoring)
{
filterMenuColorize->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::MeshColoring)
+ if (filterClass & FilterPluginInterface::MeshColoring)
{
filterMenuColorize->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Selection)
+ if (filterClass & FilterPluginInterface::Selection)
{
filterMenuSelect->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Cleaning)
+ if (filterClass & FilterPluginInterface::Cleaning)
{
filterMenuClean->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Remeshing)
+ if (filterClass & FilterPluginInterface::Remeshing)
{
filterMenuRemeshing->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Smoothing)
+ if (filterClass & FilterPluginInterface::Smoothing)
{
filterMenuSmoothing->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Normal)
+ if (filterClass & FilterPluginInterface::Normal)
{
filterMenuNormal->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Quality)
+ if (filterClass & FilterPluginInterface::Quality)
{
filterMenuQuality->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Measure)
+ if (filterClass & FilterPluginInterface::Measure)
{
filterMenuQuality->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Layer)
+ if (filterClass & FilterPluginInterface::Layer)
{
filterMenuMeshLayer->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::RasterLayer)
+ if (filterClass & FilterPluginInterface::RasterLayer)
{
filterMenuRasterLayer->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::MeshCreation)
+ if (filterClass & FilterPluginInterface::MeshCreation)
{
filterMenuCreate->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::RangeMap)
+ if (filterClass & FilterPluginInterface::RangeMap)
{
filterMenuRangeMap->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::PointSet)
+ if (filterClass & FilterPluginInterface::PointSet)
{
filterMenuPointSet->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Sampling)
+ if (filterClass & FilterPluginInterface::Sampling)
{
filterMenuSampling->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Texture)
+ if (filterClass & FilterPluginInterface::Texture)
{
filterMenuTexture->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Polygonal)
+ if (filterClass & FilterPluginInterface::Polygonal)
{
filterMenuPolygonal->addAction(filterAction);
}
- if (filterClass & MeshFilterInterface::Camera)
+ if (filterClass & FilterPluginInterface::Camera)
{
filterMenuCamera->addAction(filterAction);
}
diff --git a/src/meshlab/mainwindow_RunTime.cpp b/src/meshlab/mainwindow_RunTime.cpp
index 33a8bc3ba..78e018030 100644
--- a/src/meshlab/mainwindow_RunTime.cpp
+++ b/src/meshlab/mainwindow_RunTime.cpp
@@ -783,7 +783,7 @@ void MainWindow::runFilterScript()
int classes = 0;
int postCondMask = 0;
QAction *action = PM.actionFilterMap[ filtnm];
- MeshFilterInterface *iFilter = qobject_cast(action->parent());
+ FilterPluginInterface *iFilter = qobject_cast(action->parent());
int req=iFilter->getRequirements(action);
if (meshDoc()->mm() != NULL)
@@ -824,7 +824,7 @@ void MainWindow::runFilterScript()
atts[MLRenderingData::ATT_NAMES::ATT_VERTNORMAL] = true;
- if (iFilter->filterArity(action) == MeshFilterInterface::SINGLE_MESH)
+ if (iFilter->filterArity(action) == FilterPluginInterface::SINGLE_MESH)
{
MLRenderingData::PRIMITIVE_MODALITY pm = MLPoliciesStandAloneFunctions::bestPrimitiveModalityAccordingToMesh(meshDoc()->mm());
if ((pm != MLRenderingData::PR_ARITY) && (meshDoc()->mm() != NULL))
@@ -864,11 +864,11 @@ void MainWindow::runFilterScript()
postCondMask = iFilter->postCondition(action);
if (meshDoc()->mm() != NULL)
{
- if(classes & MeshFilterInterface::FaceColoring )
+ if(classes & FilterPluginInterface::FaceColoring )
{
meshDoc()->mm()->updateDataMask(MeshModel::MM_FACECOLOR);
}
- if(classes & MeshFilterInterface::VertexColoring )
+ if(classes & FilterPluginInterface::VertexColoring )
{
meshDoc()->mm()->updateDataMask(MeshModel::MM_VERTCOLOR);
}
@@ -881,12 +881,12 @@ void MainWindow::runFilterScript()
}
bool newmeshcreated = false;
- if (classes & MeshFilterInterface::MeshCreation)
+ if (classes & FilterPluginInterface::MeshCreation)
newmeshcreated = true;
updateSharedContextDataAfterFilterExecution(postCondMask, classes, newmeshcreated);
meshDoc()->meshDocStateData().clear();
- if(classes & MeshFilterInterface::MeshCreation)
+ if(classes & FilterPluginInterface::MeshCreation)
GLA()->resetTrackBall();
/* to be changed */
@@ -931,7 +931,7 @@ void MainWindow::startFilter()
QAction *action = qobject_cast(sender());
if (action == NULL)
throw MLException("Invalid filter action value.");
- MeshFilterInterface *iFilter = qobject_cast(action->parent());
+ FilterPluginInterface *iFilter = qobject_cast(action->parent());
if (meshDoc() == NULL)
return;
//OLD FILTER PHILOSOPHY
@@ -992,19 +992,19 @@ void MainWindow::updateSharedContextDataAfterFilterExecution(int postcondmask,in
if (mm == NULL)
continue;
//Just to be sure that the filter author didn't forget to add changing tags to the postCondition field
- if ((mm->hasDataMask(MeshModel::MM_FACECOLOR)) && (fclasses & MeshFilterInterface::FaceColoring ))
+ if ((mm->hasDataMask(MeshModel::MM_FACECOLOR)) && (fclasses & FilterPluginInterface::FaceColoring ))
postcondmask = postcondmask | MeshModel::MM_FACECOLOR;
- if ((mm->hasDataMask(MeshModel::MM_VERTCOLOR)) && (fclasses & MeshFilterInterface::VertexColoring ))
+ if ((mm->hasDataMask(MeshModel::MM_VERTCOLOR)) && (fclasses & FilterPluginInterface::VertexColoring ))
postcondmask = postcondmask | MeshModel::MM_VERTCOLOR;
- if ((mm->hasDataMask(MeshModel::MM_COLOR)) && (fclasses & MeshFilterInterface::MeshColoring ))
+ if ((mm->hasDataMask(MeshModel::MM_COLOR)) && (fclasses & FilterPluginInterface::MeshColoring ))
postcondmask = postcondmask | MeshModel::MM_COLOR;
- if ((mm->hasDataMask(MeshModel::MM_FACEQUALITY)) && (fclasses & MeshFilterInterface::Quality ))
+ if ((mm->hasDataMask(MeshModel::MM_FACEQUALITY)) && (fclasses & FilterPluginInterface::Quality ))
postcondmask = postcondmask | MeshModel::MM_FACEQUALITY;
- if ((mm->hasDataMask(MeshModel::MM_VERTQUALITY)) && (fclasses & MeshFilterInterface::Quality ))
+ if ((mm->hasDataMask(MeshModel::MM_VERTQUALITY)) && (fclasses & FilterPluginInterface::Quality ))
postcondmask = postcondmask | MeshModel::MM_VERTQUALITY;
MLRenderingData dttoberendered;
@@ -1066,7 +1066,7 @@ void MainWindow::updateSharedContextDataAfterFilterExecution(int postcondmask,in
}
MLPerViewGLOptions opts;
curr.get(opts);
- if (fclasses & MeshFilterInterface::MeshColoring)
+ if (fclasses & FilterPluginInterface::MeshColoring)
{
bool hasmeshcolor = mm->hasDataMask(MeshModel::MM_COLOR);
opts._perpoint_mesh_color_enabled = hasmeshcolor;
@@ -1137,7 +1137,7 @@ from the user defined dialog
void MainWindow::executeFilter(QAction *action, RichParameterList ¶ms, bool isPreview)
{
- MeshFilterInterface *iFilter = qobject_cast(action->parent());
+ FilterPluginInterface *iFilter = qobject_cast(action->parent());
qb->show();
iFilter->setLog(&meshDoc()->Log);
@@ -1179,7 +1179,7 @@ void MainWindow::executeFilter(QAction *action, RichParameterList ¶ms, bool
atts[MLRenderingData::ATT_NAMES::ATT_VERTPOSITION] = true;
atts[MLRenderingData::ATT_NAMES::ATT_VERTNORMAL] = true;
- if (iFilter->filterArity(action) == MeshFilterInterface::SINGLE_MESH)
+ if (iFilter->filterArity(action) == FilterPluginInterface::SINGLE_MESH)
{
MLRenderingData::PRIMITIVE_MODALITY pm = MLPoliciesStandAloneFunctions::bestPrimitiveModalityAccordingToMesh(meshDoc()->mm());
if ((pm != MLRenderingData::PR_ARITY) && (meshDoc()->mm() != NULL))
@@ -1244,16 +1244,16 @@ void MainWindow::executeFilter(QAction *action, RichParameterList ¶ms, bool
}
- MeshFilterInterface::FILTER_ARITY arity = iFilter->filterArity(action);
+ FilterPluginInterface::FILTER_ARITY arity = iFilter->filterArity(action);
QList tmp;
switch(arity)
{
- case (MeshFilterInterface::SINGLE_MESH):
+ case (FilterPluginInterface::SINGLE_MESH):
{
tmp.push_back(meshDoc()->mm());
break;
}
- case (MeshFilterInterface::FIXED):
+ case (FilterPluginInterface::FIXED):
{
for(const RichParameter& p : mergedenvironment)
{
@@ -1266,7 +1266,7 @@ void MainWindow::executeFilter(QAction *action, RichParameterList ¶ms, bool
}
break;
}
- case (MeshFilterInterface::VARIABLE):
+ case (FilterPluginInterface::VARIABLE):
{
for(MeshModel* mm = meshDoc()->nextMesh();mm != NULL;mm=meshDoc()->nextMesh(mm))
{
@@ -1279,7 +1279,7 @@ void MainWindow::executeFilter(QAction *action, RichParameterList ¶ms, bool
break;
}
- if(iFilter->getClass(action) & MeshFilterInterface::MeshCreation )
+ if(iFilter->getClass(action) & FilterPluginInterface::MeshCreation )
GLA()->resetTrackBall();
for(int jj = 0;jj < tmp.size();++jj)
@@ -1288,19 +1288,19 @@ void MainWindow::executeFilter(QAction *action, RichParameterList ¶ms, bool
if (mm != NULL)
{
// at the end for filters that change the color, or selection set the appropriate rendering mode
- if(iFilter->getClass(action) & MeshFilterInterface::FaceColoring )
+ if(iFilter->getClass(action) & FilterPluginInterface::FaceColoring )
mm->updateDataMask(MeshModel::MM_FACECOLOR);
- if(iFilter->getClass(action) & MeshFilterInterface::VertexColoring )
+ if(iFilter->getClass(action) & FilterPluginInterface::VertexColoring )
mm->updateDataMask(MeshModel::MM_VERTCOLOR);
- if(iFilter->getClass(action) & MeshFilterInterface::MeshColoring )
+ if(iFilter->getClass(action) & FilterPluginInterface::MeshColoring )
mm->updateDataMask(MeshModel::MM_COLOR);
if(iFilter->postCondition(action) & MeshModel::MM_CAMERA)
mm->updateDataMask(MeshModel::MM_CAMERA);
- if(iFilter->getClass(action) & MeshFilterInterface::Texture )
+ if(iFilter->getClass(action) & FilterPluginInterface::Texture )
updateTexture(mm->id());
}
}
diff --git a/src/meshlab/ml_std_par_dialog.cpp b/src/meshlab/ml_std_par_dialog.cpp
index 1a9d452e0..710829cea 100644
--- a/src/meshlab/ml_std_par_dialog.cpp
+++ b/src/meshlab/ml_std_par_dialog.cpp
@@ -27,7 +27,7 @@ MeshlabStdDialog::MeshlabStdDialog(QWidget *p)
}
/* manages the setup of the standard parameter window, when the execution of a plugin filter is requested */
-bool MeshlabStdDialog::showAutoDialog(MeshFilterInterface *mfi, MeshModel *mm, MeshDocument * mdp, QAction *action, MainWindow *mwi, QWidget *gla)
+bool MeshlabStdDialog::showAutoDialog(FilterPluginInterface *mfi, MeshModel *mm, MeshDocument * mdp, QAction *action, MainWindow *mwi, QWidget *gla)
{
validcache = false;
curAction = action;
@@ -69,7 +69,7 @@ void MeshlabStdDialog::changeCurrentMesh(int meshInd)
bool MeshlabStdDialog::isPreviewable()
{
- if ((curAction == NULL) || (curmfi == NULL) || (curmfi->filterArity(curAction) != MeshFilterInterface::SINGLE_MESH))
+ if ((curAction == NULL) || (curmfi == NULL) || (curmfi->filterArity(curAction) != FilterPluginInterface::SINGLE_MESH))
return false;
if ((curmask == MeshModel::MM_UNKNOWN) || (curmask == MeshModel::MM_NONE))
diff --git a/src/meshlab/ml_std_par_dialog.h b/src/meshlab/ml_std_par_dialog.h
index b36e9cd0e..a9bf467ab 100644
--- a/src/meshlab/ml_std_par_dialog.h
+++ b/src/meshlab/ml_std_par_dialog.h
@@ -26,6 +26,7 @@
#include
#include "rich_parameter_gui/richparameterlistframe.h"
+#include "../common/interfaces/filter_plugin_interface.h"
class MainWindow;
class MeshlabStdDialog : public QDockWidget
@@ -40,7 +41,7 @@ public:
void createFrame();
void loadFrameContent(MeshDocument *mdPt=0);
- bool showAutoDialog(MeshFilterInterface *mfi, MeshModel *mm, MeshDocument * md, QAction *q, MainWindow *mwi, QWidget *gla=0);
+ bool showAutoDialog(FilterPluginInterface *mfi, MeshModel *mm, MeshDocument * md, QAction *q, MainWindow *mwi, QWidget *gla=0);
bool isPreviewable();
public slots:
@@ -67,7 +68,7 @@ public:
uint curmask;
MeshModel *curModel;
MeshDocument * curMeshDoc;
- MeshFilterInterface *curmfi;
+ FilterPluginInterface *curmfi;
MainWindow *curmwi;
QWidget * curgla;
RichParameterList curParSet;
diff --git a/src/meshlab/plugindialog.cpp b/src/meshlab/plugindialog.cpp
index 26c9ec8f0..b7124250a 100644
--- a/src/meshlab/plugindialog.cpp
+++ b/src/meshlab/plugindialog.cpp
@@ -23,6 +23,7 @@
#include "plugindialog.h"
#include
+#include
#include
#include
@@ -138,7 +139,7 @@ void PluginDialog::populateTreeWidget(const QString &path,const QStringList &fil
foreach(QAction *a,iDecorate->actions()){Templist.push_back(a->text());}
addItems(pluginItem,Templist);
}
- MeshFilterInterface *iFilter = qobject_cast(plugin);
+ FilterPluginInterface *iFilter = qobject_cast(plugin);
if (iFilter){
QStringList Templist;
foreach(QAction *a,iFilter->actions()){Templist.push_back(a->text());}
@@ -205,7 +206,7 @@ void PluginDialog::displayInfo(QTreeWidgetItem* item,int /* ncolumn*/)
if (actionName==a->text())
labelInfo->setText(iDecorate->decorationInfo(a));
}
- MeshFilterInterface *iFilter = qobject_cast(plugin);
+ FilterPluginInterface *iFilter = qobject_cast(plugin);
if (iFilter)
{
foreach(QAction *a,iFilter->actions())
diff --git a/src/meshlab/rich_parameter_gui/richparameterlistframe.h b/src/meshlab/rich_parameter_gui/richparameterlistframe.h
index 50cfeacbe..089e649d5 100644
--- a/src/meshlab/rich_parameter_gui/richparameterlistframe.h
+++ b/src/meshlab/rich_parameter_gui/richparameterlistframe.h
@@ -24,8 +24,6 @@
#ifndef RICHPARAMETERLISTFRAME_H
#define RICHPARAMETERLISTFRAME_H
-#include "../../common/interfaces.h"
-
#include "richparameterwidgets.h"
#include
diff --git a/src/meshlabplugins/filter_ao/filter_ao.cpp b/src/meshlabplugins/filter_ao/filter_ao.cpp
index c089932ba..df6ae74bd 100644
--- a/src/meshlabplugins/filter_ao/filter_ao.cpp
+++ b/src/meshlabplugins/filter_ao/filter_ao.cpp
@@ -24,6 +24,8 @@
#include
#include "filter_ao.h"
#include
+#include
+#include
#include
#include
@@ -97,16 +99,16 @@ int AmbientOcclusionPlugin::getRequirements(const QAction * /*action*/)
return 0;
}
-MeshFilterInterface::FILTER_ARITY AmbientOcclusionPlugin::filterArity(const QAction*) const
+FilterPluginInterface::FILTER_ARITY AmbientOcclusionPlugin::filterArity(const QAction*) const
{
return SINGLE_MESH;
}
int getRequirements(QAction *action);
-MeshFilterInterface::FilterClass AmbientOcclusionPlugin::getClass(const QAction * /*filter*/) const
+FilterPluginInterface::FilterClass AmbientOcclusionPlugin::getClass(const QAction * /*filter*/) const
{
- return MeshFilterInterface::VertexColoring;
+ return FilterPluginInterface::VertexColoring;
//return MeshFilterInterface::FilterClass(MeshFilterInterface::FaceColoring | MeshFilterInterface::VertexColoring);
};
diff --git a/src/meshlabplugins/filter_ao/filter_ao.h b/src/meshlabplugins/filter_ao/filter_ao.h
index c1554946f..ce7b592f7 100644
--- a/src/meshlabplugins/filter_ao/filter_ao.h
+++ b/src/meshlabplugins/filter_ao/filter_ao.h
@@ -26,14 +26,14 @@
#include
-#include
+#include
#include
class AOGLWidget;
-class AmbientOcclusionPlugin : public QObject, public MeshFilterInterface
+class AmbientOcclusionPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
// Attributes
protected:
diff --git a/src/meshlabplugins/filter_camera/filter_camera.cpp b/src/meshlabplugins/filter_camera/filter_camera.cpp
index 85f432f41..e2330d137 100644
--- a/src/meshlabplugins/filter_camera/filter_camera.cpp
+++ b/src/meshlabplugins/filter_camera/filter_camera.cpp
@@ -716,16 +716,16 @@ FilterCameraPlugin::FilterClass FilterCameraPlugin::getClass(const QAction *a) c
case FP_CAMERA_TRANSLATE :
case FP_CAMERA_TRANSFORM:
case FP_SET_RASTER_CAMERA :
- return FilterClass (MeshFilterInterface::Camera + MeshFilterInterface::RasterLayer) ;
+ return FilterClass (FilterPluginInterface::Camera + FilterPluginInterface::RasterLayer) ;
case FP_QUALITY_FROM_CAMERA:
- return FilterClass(MeshFilterInterface::Camera + MeshFilterInterface::RasterLayer + MeshFilterInterface::Quality);
+ return FilterClass(FilterPluginInterface::Camera + FilterPluginInterface::RasterLayer + FilterPluginInterface::Quality);
case FP_ORIENT_NORMALS_WITH_CAMERAS:
- return FilterClass(MeshFilterInterface::Camera + MeshFilterInterface::Normal);
+ return FilterClass(FilterPluginInterface::Camera + FilterPluginInterface::Normal);
case FP_SET_MESH_CAMERA:
- return FilterClass(MeshFilterInterface::Camera + MeshFilterInterface::Layer);
+ return FilterClass(FilterPluginInterface::Camera + FilterPluginInterface::Layer);
}
assert(0);
- return MeshFilterInterface::Camera;
+ return FilterPluginInterface::Camera;
}
int FilterCameraPlugin::getPreConditions(const QAction * a) const
@@ -747,7 +747,7 @@ int FilterCameraPlugin::getPreConditions(const QAction * a) const
return 0;
}
-MeshFilterInterface::FILTER_ARITY FilterCameraPlugin::filterArity(const QAction* act ) const
+FilterPluginInterface::FILTER_ARITY FilterCameraPlugin::filterArity(const QAction* act ) const
{
switch (ID(act))
{
diff --git a/src/meshlabplugins/filter_camera/filter_camera.h b/src/meshlabplugins/filter_camera/filter_camera.h
index 2fd89f42b..4755f019f 100644
--- a/src/meshlabplugins/filter_camera/filter_camera.h
+++ b/src/meshlabplugins/filter_camera/filter_camera.h
@@ -26,13 +26,13 @@
#include
-#include
+#include
-class FilterCameraPlugin : public QObject, public MeshFilterInterface
+class FilterCameraPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum { FP_SET_MESH_CAMERA,
diff --git a/src/meshlabplugins/filter_clean/cleanfilter.cpp b/src/meshlabplugins/filter_clean/cleanfilter.cpp
index 4c183745f..947d88676 100644
--- a/src/meshlabplugins/filter_clean/cleanfilter.cpp
+++ b/src/meshlabplugins/filter_clean/cleanfilter.cpp
@@ -159,12 +159,12 @@ QString CleanFilter::filterName(FilterIDType filter) const
case FP_REMOVE_UNREFERENCED_VERTEX:
case FP_REMOVE_DUPLICATED_VERTEX:
case FP_COMPACT_VERT:
- case FP_COMPACT_FACE: return MeshFilterInterface::Cleaning;
- case FP_BALL_PIVOTING: return MeshFilterInterface::Remeshing;
- case FP_MERGE_WEDGE_TEX: return MeshFilterInterface::FilterClass(MeshFilterInterface::Cleaning + MeshFilterInterface::Texture);
+ case FP_COMPACT_FACE: return FilterPluginInterface::Cleaning;
+ case FP_BALL_PIVOTING: return FilterPluginInterface::Remeshing;
+ case FP_MERGE_WEDGE_TEX: return FilterPluginInterface::FilterClass(FilterPluginInterface::Cleaning + FilterPluginInterface::Texture);
default : assert(0);
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
int CleanFilter::getRequirements(const QAction *action)
diff --git a/src/meshlabplugins/filter_clean/cleanfilter.h b/src/meshlabplugins/filter_clean/cleanfilter.h
index 84aea1b2c..49da2bf0d 100644
--- a/src/meshlabplugins/filter_clean/cleanfilter.h
+++ b/src/meshlabplugins/filter_clean/cleanfilter.h
@@ -25,13 +25,13 @@
#define __CLEAN_FILTER_H__
#include
-#include
+#include
-class CleanFilter : public QObject, public MeshFilterInterface
+class CleanFilter : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
/* naming convention :
diff --git a/src/meshlabplugins/filter_color_projection/filter_color_projection.cpp b/src/meshlabplugins/filter_color_projection/filter_color_projection.cpp
index 0db938b05..03f410f39 100644
--- a/src/meshlabplugins/filter_color_projection/filter_color_projection.cpp
+++ b/src/meshlabplugins/filter_color_projection/filter_color_projection.cpp
@@ -932,7 +932,7 @@ FilterColorProjectionPlugin::FilterClass FilterColorProjectionPlugin::getClass(c
return FilterClass(Camera + Texture);
break;
default : assert(0);
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
}
diff --git a/src/meshlabplugins/filter_color_projection/filter_color_projection.h b/src/meshlabplugins/filter_color_projection/filter_color_projection.h
index 7cf9d8166..0ad1e20eb 100644
--- a/src/meshlabplugins/filter_color_projection/filter_color_projection.h
+++ b/src/meshlabplugins/filter_color_projection/filter_color_projection.h
@@ -25,13 +25,13 @@
#define FILTER_COLORPROJ_H
#include
-#include
+#include
-class FilterColorProjectionPlugin : public QObject, public MeshFilterInterface
+class FilterColorProjectionPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum { FP_SINGLEIMAGEPROJ, FP_MULTIIMAGETRIVIALPROJ, FP_MULTIIMAGETRIVIALPROJTEXTURE };
diff --git a/src/meshlabplugins/filter_colorproc/filter_colorproc.cpp b/src/meshlabplugins/filter_colorproc/filter_colorproc.cpp
index 18bee1a62..11aaa16af 100644
--- a/src/meshlabplugins/filter_colorproc/filter_colorproc.cpp
+++ b/src/meshlabplugins/filter_colorproc/filter_colorproc.cpp
@@ -915,7 +915,7 @@ bool FilterColorProc::applyFilter(const QAction *filter, MeshDocument &md, const
return false;
}
- MeshFilterInterface::FilterClass FilterColorProc::getClass(const QAction *a) const
+ FilterPluginInterface::FilterClass FilterColorProc::getClass(const QAction *a) const
{
switch(ID(a))
{
@@ -933,10 +933,10 @@ bool FilterColorProc::applyFilter(const QAction *filter, MeshDocument &md, const
case CP_MAP_VQUALITY_INTO_COLOR:
case CP_VERTEX_SMOOTH:
case CP_FACE_TO_VERTEX:
- case CP_TEXTURE_TO_VERTEX: return MeshFilterInterface::VertexColoring;
- case CP_SCATTER_PER_MESH: return MeshFilterInterface::MeshColoring;
+ case CP_TEXTURE_TO_VERTEX: return FilterPluginInterface::VertexColoring;
+ case CP_SCATTER_PER_MESH: return FilterPluginInterface::MeshColoring;
case CP_SATURATE_QUALITY:
- case CP_CLAMP_QUALITY: return MeshFilterInterface::Quality;
+ case CP_CLAMP_QUALITY: return FilterPluginInterface::Quality;
case CP_DISCRETE_CURVATURE: return FilterClass(Normal + VertexColoring);
case CP_TRIANGLE_QUALITY: return FilterClass(Quality + FaceColoring);
case CP_RANDOM_FACE:
@@ -944,10 +944,10 @@ bool FilterColorProc::applyFilter(const QAction *filter, MeshDocument &md, const
case CP_FACE_SMOOTH:
case CP_VERTEX_TO_FACE:
case CP_MESH_TO_FACE:
- case CP_MAP_FQUALITY_INTO_COLOR: return MeshFilterInterface::FaceColoring;
+ case CP_MAP_FQUALITY_INTO_COLOR: return FilterPluginInterface::FaceColoring;
default: assert(0);
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
int FilterColorProc::postCondition( const QAction* filter ) const
@@ -1022,7 +1022,7 @@ int FilterColorProc::getPreConditions(const QAction* filter ) const
return MeshModel::MM_NONE;
}
-MeshFilterInterface::FILTER_ARITY FilterColorProc::filterArity(const QAction* act ) const
+FilterPluginInterface::FILTER_ARITY FilterColorProc::filterArity(const QAction* act ) const
{
switch(ID(act))
{
@@ -1050,12 +1050,12 @@ MeshFilterInterface::FILTER_ARITY FilterColorProc::filterArity(const QAction* ac
case CP_MAP_FQUALITY_INTO_COLOR:
case CP_FACE_TO_VERTEX:
case CP_FACE_SMOOTH:
- case CP_TEXTURE_TO_VERTEX: return MeshFilterInterface::SINGLE_MESH;
- case CP_SCATTER_PER_MESH: return MeshFilterInterface::VARIABLE;
+ case CP_TEXTURE_TO_VERTEX: return FilterPluginInterface::SINGLE_MESH;
+ case CP_SCATTER_PER_MESH: return FilterPluginInterface::VARIABLE;
default: assert(0);
}
- return MeshFilterInterface::SINGLE_MESH;
+ return FilterPluginInterface::SINGLE_MESH;
}
diff --git a/src/meshlabplugins/filter_colorproc/filter_colorproc.h b/src/meshlabplugins/filter_colorproc/filter_colorproc.h
index 9c5239b1e..0e00c8966 100644
--- a/src/meshlabplugins/filter_colorproc/filter_colorproc.h
+++ b/src/meshlabplugins/filter_colorproc/filter_colorproc.h
@@ -25,14 +25,14 @@
#define FILTERCOLORPROCPLUGIN_H
#include
-#include
+#include
-class FilterColorProc : public QObject, public MeshFilterInterface
+class FilterColorProc : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum { CP_FILLING,
diff --git a/src/meshlabplugins/filter_create/filter_create.cpp b/src/meshlabplugins/filter_create/filter_create.cpp
index ee117ffbd..167b4e302 100644
--- a/src/meshlabplugins/filter_create/filter_create.cpp
+++ b/src/meshlabplugins/filter_create/filter_create.cpp
@@ -527,7 +527,7 @@ bool FilterCreate::applyFilter(const QAction *filter, MeshDocument &md, const Ri
return true;
}
- MeshFilterInterface::FilterClass FilterCreate::getClass(const QAction *a) const
+ FilterPluginInterface::FilterClass FilterCreate::getClass(const QAction *a) const
{
switch(ID(a))
{
@@ -543,11 +543,11 @@ bool FilterCreate::applyFilter(const QAction *filter, MeshDocument &md, const Ri
case CR_CONE:
case CR_TORUS:
case CR_FITPLANE:
- return MeshFilterInterface::MeshCreation;
+ return FilterPluginInterface::MeshCreation;
break;
default:
assert(0);
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
}
diff --git a/src/meshlabplugins/filter_create/filter_create.h b/src/meshlabplugins/filter_create/filter_create.h
index 515b2ef14..84441eed1 100644
--- a/src/meshlabplugins/filter_create/filter_create.h
+++ b/src/meshlabplugins/filter_create/filter_create.h
@@ -23,13 +23,13 @@
#ifndef FILTER_CREATE_H
#define FILTER_CREATE_H
-#include
+#include
-class FilterCreate : public QObject, public MeshFilterInterface
+class FilterCreate : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum {
diff --git a/src/meshlabplugins/filter_createiso/filter_createiso.cpp b/src/meshlabplugins/filter_createiso/filter_createiso.cpp
index 54b69e1fc..6cefd11ad 100644
--- a/src/meshlabplugins/filter_createiso/filter_createiso.cpp
+++ b/src/meshlabplugins/filter_createiso/filter_createiso.cpp
@@ -83,8 +83,8 @@ QString FilterCreateIso::pluginName() const
{
switch(ID(a))
{
- case FP_CREATEISO : return MeshFilterInterface::MeshCreation;
- default : return MeshFilterInterface::Generic;
+ case FP_CREATEISO : return FilterPluginInterface::MeshCreation;
+ default : return FilterPluginInterface::Generic;
}
}
diff --git a/src/meshlabplugins/filter_createiso/filter_createiso.h b/src/meshlabplugins/filter_createiso/filter_createiso.h
index 7a31ce26f..429ef86f7 100644
--- a/src/meshlabplugins/filter_createiso/filter_createiso.h
+++ b/src/meshlabplugins/filter_createiso/filter_createiso.h
@@ -33,14 +33,14 @@ Added the new sample filter plugin that removes border faces
#define FILTERCREATEISO_PLUGIN_H
#include
-#include
+#include
-class FilterCreateIso : public QObject, public MeshFilterInterface
+class FilterCreateIso : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
/* naming convention :
diff --git a/src/meshlabplugins/filter_csg/filter_csg.h b/src/meshlabplugins/filter_csg/filter_csg.h
index 9f1a12b2b..a70c5e77c 100644
--- a/src/meshlabplugins/filter_csg/filter_csg.h
+++ b/src/meshlabplugins/filter_csg/filter_csg.h
@@ -28,18 +28,17 @@
#include
#include
-#include
-#include
+#include
//FILE _iob[] = { *stdin, *stdout, *stderr };
//extern "C" FILE * __cdecl __iob_func(void) { return _iob; }
-class FilterCSG : public QObject, public MeshFilterInterface
+class FilterCSG : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
enum {
CSG_OPERATION_INTERSECTION = 0,
@@ -63,7 +62,7 @@ public:
virtual bool applyFilter(const QAction*, MeshDocument &, const RichParameterList &, vcg::CallBackPos *);
- virtual FilterClass getClass(const QAction *) const { return MeshFilterInterface::FilterClass( MeshFilterInterface::Layer + MeshFilterInterface::Remeshing ); }
+ virtual FilterClass getClass(const QAction *) const { return FilterPluginInterface::FilterClass( FilterPluginInterface::Layer + FilterPluginInterface::Remeshing ); }
FILTER_ARITY filterArity(const QAction*) const {return FIXED;}
};
diff --git a/src/meshlabplugins/filter_dirt/filter_dirt.cpp b/src/meshlabplugins/filter_dirt/filter_dirt.cpp
index f1b648343..ea321162f 100644
--- a/src/meshlabplugins/filter_dirt/filter_dirt.cpp
+++ b/src/meshlabplugins/filter_dirt/filter_dirt.cpp
@@ -253,14 +253,14 @@ int FilterDirt::postCondition(const QAction *a) const
return MeshModel::MM_ALL;
}
-MeshFilterInterface::FilterClass FilterDirt::getClass(const QAction *filter) const
+FilterPluginInterface::FilterClass FilterDirt::getClass(const QAction *filter) const
{
switch (ID(filter)) {
- case FP_DIRT:return MeshFilterInterface::Sampling;
- case FP_CLOUD_MOVEMENT:return MeshFilterInterface::Remeshing;
+ case FP_DIRT:return FilterPluginInterface::Sampling;
+ case FP_CLOUD_MOVEMENT:return FilterPluginInterface::Remeshing;
default:assert(0);
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
MESHLAB_PLUGIN_NAME_EXPORTER(FilterDirt)
diff --git a/src/meshlabplugins/filter_dirt/filter_dirt.h b/src/meshlabplugins/filter_dirt/filter_dirt.h
index 984fed86c..275ffda51 100644
--- a/src/meshlabplugins/filter_dirt/filter_dirt.h
+++ b/src/meshlabplugins/filter_dirt/filter_dirt.h
@@ -27,8 +27,7 @@
#include
#include
#include
-#include
-#include
+#include
#include
#include
//#include "muParser.h"
@@ -37,11 +36,11 @@ using namespace vcg;
//using namespace mu;
-class FilterDirt : public QObject, public MeshFilterInterface
+class FilterDirt : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
protected:
double x,y,z,nx,ny,nz,r,g,b,q,rad;
//double x0,y0,z0,x1,y1,z1,x2,y2,z2,nx0,ny0,nz0,nx1,ny1,nz1,nx2,ny2,nz2,r0,g0,b0,r1,g1,b1,r2,g2,b2,q0,q1,q2;
diff --git a/src/meshlabplugins/filter_fractal/filter_fractal.cpp b/src/meshlabplugins/filter_fractal/filter_fractal.cpp
index c4eb0df75..c4e0b23cc 100644
--- a/src/meshlabplugins/filter_fractal/filter_fractal.cpp
+++ b/src/meshlabplugins/filter_fractal/filter_fractal.cpp
@@ -257,7 +257,7 @@ void FilterFractal::initParameterSetForCratersGeneration(MeshDocument &md, RichP
bool FilterFractal::applyFilter(const QAction* filter, MeshDocument &md, const RichParameterList &par, vcg::CallBackPos* cb)
{
- if(this->getClass(filter) == MeshFilterInterface::MeshCreation)
+ if(this->getClass(filter) == FilterPluginInterface::MeshCreation)
md.addNewMesh("",this->filterName(ID(filter)));
switch(ID(filter))
{
@@ -338,18 +338,18 @@ bool FilterFractal::applyFilter(const QAction* filter, MeshDocument &md, const R
return false;
}
-MeshFilterInterface::FilterClass FilterFractal::getClass(const QAction* filter) const
+FilterPluginInterface::FilterClass FilterFractal::getClass(const QAction* filter) const
{
switch(ID(filter)) {
case CR_FRACTAL_TERRAIN:
- return MeshFilterInterface::MeshCreation;
+ return FilterPluginInterface::MeshCreation;
break;
case FP_FRACTAL_MESH:
case FP_CRATERS:
- return MeshFilterInterface::Smoothing;
+ return FilterPluginInterface::Smoothing;
break;
default: assert(0);
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
}
@@ -382,18 +382,18 @@ int FilterFractal::postCondition(const QAction *filter) const
return MeshModel::MM_ALL;
}
-MeshFilterInterface::FILTER_ARITY FilterFractal::filterArity(const QAction* act ) const
+FilterPluginInterface::FILTER_ARITY FilterFractal::filterArity(const QAction* act ) const
{
switch(ID(act))
{
case FP_FRACTAL_MESH:
- return MeshFilterInterface::SINGLE_MESH;
+ return FilterPluginInterface::SINGLE_MESH;
case CR_FRACTAL_TERRAIN:
- return MeshFilterInterface::NONE;
+ return FilterPluginInterface::NONE;
case FP_CRATERS:
- return MeshFilterInterface::VARIABLE;
+ return FilterPluginInterface::VARIABLE;
}
- return MeshFilterInterface::NONE;
+ return FilterPluginInterface::NONE;
}
// ----------------------------------------------------------------------
diff --git a/src/meshlabplugins/filter_fractal/filter_fractal.h b/src/meshlabplugins/filter_fractal/filter_fractal.h
index 3a2bad26d..c5c26c518 100644
--- a/src/meshlabplugins/filter_fractal/filter_fractal.h
+++ b/src/meshlabplugins/filter_fractal/filter_fractal.h
@@ -28,14 +28,14 @@
#include
#include
-#include
+#include
#include "craters_utils.h"
-class FilterFractal : public QObject, public MeshFilterInterface
+class FilterFractal : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
FilterFractal();
diff --git a/src/meshlabplugins/filter_func/filter_func.cpp b/src/meshlabplugins/filter_func/filter_func.cpp
index d5dd344c0..3368d7efa 100644
--- a/src/meshlabplugins/filter_func/filter_func.cpp
+++ b/src/meshlabplugins/filter_func/filter_func.cpp
@@ -166,22 +166,22 @@ FilterFunctionPlugin::FilterClass FilterFunctionPlugin::getClass(const QAction *
switch(ID(a))
{
case FF_FACE_SELECTION:
- case FF_VERT_SELECTION: return MeshFilterInterface::Selection;
+ case FF_VERT_SELECTION: return FilterPluginInterface::Selection;
case FF_FACE_QUALITY: return FilterClass(Quality + FaceColoring);
case FF_VERT_QUALITY: return FilterClass(Quality + VertexColoring);
- case FF_VERT_TEXTURE_FUNC: return MeshFilterInterface::Texture;
- case FF_VERT_COLOR: return MeshFilterInterface::VertexColoring;
- case FF_VERT_NORMAL: return MeshFilterInterface::Normal;
- case FF_FACE_COLOR: return MeshFilterInterface::FaceColoring;
- case FF_WEDGE_TEXTURE_FUNC: return MeshFilterInterface::Texture;
- case FF_ISOSURFACE: return MeshFilterInterface::MeshCreation;
- case FF_GRID: return MeshFilterInterface::MeshCreation;
- case FF_REFINE: return MeshFilterInterface::Remeshing;
- case FF_GEOM_FUNC: return MeshFilterInterface::Smoothing;
- case FF_DEF_VERT_ATTRIB: return MeshFilterInterface::Layer;
- case FF_DEF_FACE_ATTRIB: return MeshFilterInterface::Layer;
+ case FF_VERT_TEXTURE_FUNC: return FilterPluginInterface::Texture;
+ case FF_VERT_COLOR: return FilterPluginInterface::VertexColoring;
+ case FF_VERT_NORMAL: return FilterPluginInterface::Normal;
+ case FF_FACE_COLOR: return FilterPluginInterface::FaceColoring;
+ case FF_WEDGE_TEXTURE_FUNC: return FilterPluginInterface::Texture;
+ case FF_ISOSURFACE: return FilterPluginInterface::MeshCreation;
+ case FF_GRID: return FilterPluginInterface::MeshCreation;
+ case FF_REFINE: return FilterPluginInterface::Remeshing;
+ case FF_GEOM_FUNC: return FilterPluginInterface::Smoothing;
+ case FF_DEF_VERT_ATTRIB: return FilterPluginInterface::Layer;
+ case FF_DEF_FACE_ATTRIB: return FilterPluginInterface::Layer;
- default: return MeshFilterInterface::Generic;
+ default: return FilterPluginInterface::Generic;
}
}
@@ -375,7 +375,7 @@ void FilterFunctionPlugin::initParameterList(const QAction *action,MeshModel &m,
// The Real Core Function doing the actual mesh processing.
bool FilterFunctionPlugin::applyFilter(const QAction *filter, MeshDocument &md, const RichParameterList & par, vcg::CallBackPos *cb)
{
- if(this->getClass(filter) == MeshFilterInterface::MeshCreation)
+ if(this->getClass(filter) == FilterPluginInterface::MeshCreation)
md.addNewMesh("",this->filterName(ID(filter)));
MeshModel &m=*(md.mm());
Q_UNUSED(cb);
@@ -1433,7 +1433,7 @@ void FilterFunctionPlugin::setPerFaceVariables(Parser &p, CMeshO &m)
}
-MeshFilterInterface::FILTER_ARITY FilterFunctionPlugin::filterArity(const QAction* filter ) const
+FilterPluginInterface::FILTER_ARITY FilterFunctionPlugin::filterArity(const QAction* filter ) const
{
switch(ID(filter))
{
@@ -1450,12 +1450,12 @@ MeshFilterInterface::FILTER_ARITY FilterFunctionPlugin::filterArity(const QActio
case FF_DEF_VERT_ATTRIB:
case FF_DEF_FACE_ATTRIB:
case FF_REFINE:
- return MeshFilterInterface::SINGLE_MESH;
+ return FilterPluginInterface::SINGLE_MESH;
case FF_GRID:
case FF_ISOSURFACE:
- return MeshFilterInterface::NONE;
+ return FilterPluginInterface::NONE;
}
- return MeshFilterInterface::NONE;
+ return FilterPluginInterface::NONE;
}
diff --git a/src/meshlabplugins/filter_func/filter_func.h b/src/meshlabplugins/filter_func/filter_func.h
index de37f49b4..61b873cec 100644
--- a/src/meshlabplugins/filter_func/filter_func.h
+++ b/src/meshlabplugins/filter_func/filter_func.h
@@ -26,16 +26,16 @@
#include
-#include
+#include
#include "muParser.h"
#include "filter_refine.h"
-class FilterFunctionPlugin : public QObject, public MeshFilterInterface
+class FilterFunctionPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
protected:
double x,y,z,nx,ny,nz,r,g,b,a,q,rad,vtu,vtv,vsel;
diff --git a/src/meshlabplugins/filter_geodesic/filter_geodesic.cpp b/src/meshlabplugins/filter_geodesic/filter_geodesic.cpp
index f5ad6e15d..553aa4f28 100644
--- a/src/meshlabplugins/filter_geodesic/filter_geodesic.cpp
+++ b/src/meshlabplugins/filter_geodesic/filter_geodesic.cpp
@@ -90,10 +90,10 @@ FilterGeodesic::FilterClass FilterGeodesic::getClass(const QAction *a) const
{
case FP_QUALITY_BORDER_GEODESIC :
case FP_QUALITY_SELECTED_GEODESIC :
- case FP_QUALITY_POINT_GEODESIC : return FilterGeodesic::FilterClass(MeshFilterInterface::VertexColoring + MeshFilterInterface::Quality);
+ case FP_QUALITY_POINT_GEODESIC : return FilterGeodesic::FilterClass(FilterPluginInterface::VertexColoring + FilterPluginInterface::Quality);
default : assert(0);
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
int FilterGeodesic::getRequirements(const QAction *action)
diff --git a/src/meshlabplugins/filter_geodesic/filter_geodesic.h b/src/meshlabplugins/filter_geodesic/filter_geodesic.h
index 78aadfbe4..ceb56f47c 100644
--- a/src/meshlabplugins/filter_geodesic/filter_geodesic.h
+++ b/src/meshlabplugins/filter_geodesic/filter_geodesic.h
@@ -24,15 +24,15 @@
#define FILTERGEODESIC_PLUGIN_H
#include
-#include
+#include
#include
-class FilterGeodesic : public QObject, public MeshFilterInterface
+class FilterGeodesic : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
/* naming convention :
diff --git a/src/meshlabplugins/filter_globalregistration/globalregistration.cpp b/src/meshlabplugins/filter_globalregistration/globalregistration.cpp
index 2cfe4bebf..d8d86dd09 100644
--- a/src/meshlabplugins/filter_globalregistration/globalregistration.cpp
+++ b/src/meshlabplugins/filter_globalregistration/globalregistration.cpp
@@ -65,10 +65,10 @@ GlobalRegistrationPlugin::FilterClass GlobalRegistrationPlugin::getClass(const Q
{
switch(ID(a))
{
- case FP_GLOBAL_REGISTRATION : return MeshFilterInterface::PointSet;
+ case FP_GLOBAL_REGISTRATION : return FilterPluginInterface::PointSet;
default : assert(0);
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
void GlobalRegistrationPlugin::initParameterList(const QAction *action,MeshDocument &md, RichParameterList & parlst)
diff --git a/src/meshlabplugins/filter_globalregistration/globalregistration.h b/src/meshlabplugins/filter_globalregistration/globalregistration.h
index 7370571f6..37152dc11 100644
--- a/src/meshlabplugins/filter_globalregistration/globalregistration.h
+++ b/src/meshlabplugins/filter_globalregistration/globalregistration.h
@@ -24,13 +24,13 @@
#ifndef SAMPLEFILTERSPLUGIN_H
#define SAMPLEFILTERSPLUGIN_H
-#include
+#include
-class GlobalRegistrationPlugin : public QObject, public MeshFilterInterface
+class GlobalRegistrationPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum { FP_GLOBAL_REGISTRATION } ;
diff --git a/src/meshlabplugins/filter_img_patch_param/filter_img_patch_param.cpp b/src/meshlabplugins/filter_img_patch_param/filter_img_patch_param.cpp
index c06426e93..33dede14a 100644
--- a/src/meshlabplugins/filter_img_patch_param/filter_img_patch_param.cpp
+++ b/src/meshlabplugins/filter_img_patch_param/filter_img_patch_param.cpp
@@ -97,7 +97,7 @@ int FilterImgPatchParamPlugin::getRequirements(const QAction *act )
}
-MeshFilterInterface::FilterClass FilterImgPatchParamPlugin::getClass(const QAction *act ) const
+FilterPluginInterface::FilterClass FilterImgPatchParamPlugin::getClass(const QAction *act ) const
{
switch( ID(act) )
{
@@ -105,7 +105,7 @@ MeshFilterInterface::FilterClass FilterImgPatchParamPlugin::getClass(const QActi
case FP_PATCH_PARAM_AND_TEXTURING: return Texture;
case FP_RASTER_VERT_COVERAGE:
case FP_RASTER_FACE_COVERAGE: return FilterClass(Quality + Camera + Texture);
- default: assert(0); return MeshFilterInterface::Generic;
+ default: assert(0); return FilterPluginInterface::Generic;
}
}
diff --git a/src/meshlabplugins/filter_img_patch_param/filter_img_patch_param.h b/src/meshlabplugins/filter_img_patch_param/filter_img_patch_param.h
index 7b1e7c01a..f81f8dca8 100644
--- a/src/meshlabplugins/filter_img_patch_param/filter_img_patch_param.h
+++ b/src/meshlabplugins/filter_img_patch_param/filter_img_patch_param.h
@@ -28,18 +28,18 @@
#include
-#include
+#include
#include
#include "Patch.h"
#include
class VisibleSet;
-class FilterImgPatchParamPlugin : public QObject, public MeshFilterInterface
+class FilterImgPatchParamPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES( MeshFilterInterface )
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES( FilterPluginInterface )
enum
{
diff --git a/src/meshlabplugins/filter_isoparametrization/filter_isoparametrization.cpp b/src/meshlabplugins/filter_isoparametrization/filter_isoparametrization.cpp
index 76c2ce44c..82dcd1691 100644
--- a/src/meshlabplugins/filter_isoparametrization/filter_isoparametrization.cpp
+++ b/src/meshlabplugins/filter_isoparametrization/filter_isoparametrization.cpp
@@ -453,9 +453,9 @@ bool FilterIsoParametrization::applyFilter(const QAction *filter, MeshDocument&
return false;
}
-MeshFilterInterface::FilterClass FilterIsoParametrization::getClass(const QAction *) const
+FilterPluginInterface::FilterClass FilterIsoParametrization::getClass(const QAction *) const
{
- return MeshFilterInterface::Remeshing;
+ return FilterPluginInterface::Remeshing;
}
int FilterIsoParametrization::postCondition(const QAction* /*filter*/ ) const
@@ -463,18 +463,18 @@ int FilterIsoParametrization::postCondition(const QAction* /*filter*/ ) const
return MeshModel::MM_WEDGTEXCOORD | MeshModel::MM_VERTTEXCOORD;
}
-MeshFilterInterface::FILTER_ARITY FilterIsoParametrization::filterArity(const QAction* filter) const
+FilterPluginInterface::FILTER_ARITY FilterIsoParametrization::filterArity(const QAction* filter) const
{
switch(ID(filter))
{
case ISOP_PARAM :
case ISOP_REMESHING :
case ISOP_DIAMPARAM :
- return MeshFilterInterface::SINGLE_MESH;
+ return FilterPluginInterface::SINGLE_MESH;
case ISOP_TRANSFER:
- return MeshFilterInterface::FIXED;
+ return FilterPluginInterface::FIXED;
}
- return MeshFilterInterface::NONE;
+ return FilterPluginInterface::NONE;
}
diff --git a/src/meshlabplugins/filter_isoparametrization/filter_isoparametrization.h b/src/meshlabplugins/filter_isoparametrization/filter_isoparametrization.h
index 40db6affa..4ca831dd8 100644
--- a/src/meshlabplugins/filter_isoparametrization/filter_isoparametrization.h
+++ b/src/meshlabplugins/filter_isoparametrization/filter_isoparametrization.h
@@ -29,13 +29,13 @@
#include
#include
#include
-#include
+#include
-class FilterIsoParametrization : public QObject, public MeshFilterInterface
+class FilterIsoParametrization : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum {ISOP_PARAM,
diff --git a/src/meshlabplugins/filter_layer/filter_layer.cpp b/src/meshlabplugins/filter_layer/filter_layer.cpp
index 23c72f337..1a9fd8286 100644
--- a/src/meshlabplugins/filter_layer/filter_layer.cpp
+++ b/src/meshlabplugins/filter_layer/filter_layer.cpp
@@ -29,6 +29,8 @@
#include
#include
+#include
+#include
@@ -849,18 +851,18 @@ FilterLayerPlugin::FilterClass FilterLayerPlugin::getClass(const QAction *a) con
case FP_MESH_VISIBILITY :
case FP_SPLITCONNECTED :
case FP_DELETE_MESH :
- case FP_DELETE_NON_VISIBLE_MESH : return MeshFilterInterface::Layer;
+ case FP_DELETE_NON_VISIBLE_MESH : return FilterPluginInterface::Layer;
case FP_RENAME_RASTER :
case FP_DELETE_RASTER :
case FP_DELETE_NON_SELECTED_RASTER :
- case FP_EXPORT_CAMERAS: return MeshFilterInterface::RasterLayer;
- case FP_IMPORT_CAMERAS: return FilterClass(MeshFilterInterface::Camera + MeshFilterInterface::RasterLayer);
+ case FP_EXPORT_CAMERAS: return FilterPluginInterface::RasterLayer;
+ case FP_IMPORT_CAMERAS: return FilterClass(FilterPluginInterface::Camera + FilterPluginInterface::RasterLayer);
default : assert(0);
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
-MeshFilterInterface::FILTER_ARITY FilterLayerPlugin::filterArity(const QAction* filter) const
+FilterPluginInterface::FILTER_ARITY FilterLayerPlugin::filterArity(const QAction* filter) const
{
switch(ID(filter))
{
@@ -872,18 +874,18 @@ MeshFilterInterface::FILTER_ARITY FilterLayerPlugin::filterArity(const QAction*
case FP_SELECTCURRENT :
case FP_SPLITCONNECTED :
case FP_DELETE_MESH :
- return MeshFilterInterface::SINGLE_MESH;
+ return FilterPluginInterface::SINGLE_MESH;
case FP_RENAME_RASTER :
case FP_DELETE_RASTER :
case FP_DELETE_NON_SELECTED_RASTER :
case FP_EXPORT_CAMERAS:
case FP_IMPORT_CAMERAS:
- return MeshFilterInterface::NONE;
+ return FilterPluginInterface::NONE;
case FP_FLATTEN :
case FP_DELETE_NON_VISIBLE_MESH :
- return MeshFilterInterface::VARIABLE;
+ return FilterPluginInterface::VARIABLE;
}
- return MeshFilterInterface::NONE;
+ return FilterPluginInterface::NONE;
}
int FilterLayerPlugin::postCondition(const QAction* filter) const
@@ -909,7 +911,7 @@ int FilterLayerPlugin::postCondition(const QAction* filter) const
default: assert(0);
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
MESHLAB_PLUGIN_NAME_EXPORTER(FilterLayerPlugin)
diff --git a/src/meshlabplugins/filter_layer/filter_layer.h b/src/meshlabplugins/filter_layer/filter_layer.h
index baa038207..17eb080fb 100644
--- a/src/meshlabplugins/filter_layer/filter_layer.h
+++ b/src/meshlabplugins/filter_layer/filter_layer.h
@@ -26,13 +26,13 @@
#include
-#include
+#include
-class FilterLayerPlugin : public QObject, public MeshFilterInterface
+class FilterLayerPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum {
diff --git a/src/meshlabplugins/filter_measure/filter_measure.cpp b/src/meshlabplugins/filter_measure/filter_measure.cpp
index fa54f610e..50f1a87e0 100644
--- a/src/meshlabplugins/filter_measure/filter_measure.cpp
+++ b/src/meshlabplugins/filter_measure/filter_measure.cpp
@@ -127,10 +127,10 @@ QString FilterMeasurePlugin::filterName(FilterIDType filterId) const
FilterMeasurePlugin::FilterClass FilterMeasurePlugin::getClass(const QAction *) const
{
- return MeshFilterInterface::Measure;
+ return FilterPluginInterface::Measure;
}
-MeshFilterInterface::FILTER_ARITY FilterMeasurePlugin::filterArity(const QAction*) const
+FilterPluginInterface::FILTER_ARITY FilterMeasurePlugin::filterArity(const QAction*) const
{
return SINGLE_MESH;
}
diff --git a/src/meshlabplugins/filter_measure/filter_measure.h b/src/meshlabplugins/filter_measure/filter_measure.h
index bd79c6e76..317e5f4bc 100644
--- a/src/meshlabplugins/filter_measure/filter_measure.h
+++ b/src/meshlabplugins/filter_measure/filter_measure.h
@@ -24,13 +24,13 @@
#ifndef FILTER_MEASURE_H
#define FILTER_MEASURE_H
-#include
+#include
-class FilterMeasurePlugin : public QObject, public MeshFilterInterface
+class FilterMeasurePlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum {
diff --git a/src/meshlabplugins/filter_meshing/meshfilter.cpp b/src/meshlabplugins/filter_meshing/meshfilter.cpp
index 857f2f347..5d840cd31 100644
--- a/src/meshlabplugins/filter_meshing/meshfilter.cpp
+++ b/src/meshlabplugins/filter_meshing/meshfilter.cpp
@@ -133,7 +133,7 @@ ExtraMeshFilterPlugin::FilterClass ExtraMeshFilterPlugin::getClass(const QAction
case FP_FAUX_CREASE :
case FP_FAUX_EXTRACT :
case FP_VATTR_SEAM :
- case FP_REFINE_LS3_LOOP : return MeshFilterInterface::Remeshing;
+ case FP_REFINE_LS3_LOOP : return FilterPluginInterface::Remeshing;
case FP_REFINE_CATMULL :
case FP_REFINE_HALF_CATMULL :
case FP_QUAD_DOMINANT :
@@ -150,7 +150,7 @@ ExtraMeshFilterPlugin::FilterClass ExtraMeshFilterPlugin::getClass(const QAction
case FP_CENTER :
case FP_SCALE :
case FP_PRINCIPAL_AXIS :
- case FP_FLIP_AND_SWAP : return MeshFilterInterface::Normal;
+ case FP_FLIP_AND_SWAP : return FilterPluginInterface::Normal;
case FP_COMPUTE_PRINC_CURV_DIR : return FilterClass( Normal + VertexColoring );
@@ -162,12 +162,12 @@ ExtraMeshFilterPlugin::FilterClass ExtraMeshFilterPlugin::getClass(const QAction
case FP_PERIMETER_POLYLINE :
case FP_SLICE_WITH_A_PLANE :
- case FP_CYLINDER_UNWRAP : return MeshFilterInterface::Measure;
+ case FP_CYLINDER_UNWRAP : return FilterPluginInterface::Measure;
- default : assert(0); return MeshFilterInterface::Generic;
+ default : assert(0); return FilterPluginInterface::Generic;
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
int ExtraMeshFilterPlugin::getPreCondition(QAction *filter) const
diff --git a/src/meshlabplugins/filter_meshing/meshfilter.h b/src/meshlabplugins/filter_meshing/meshfilter.h
index 3e2bc792b..0255b7344 100644
--- a/src/meshlabplugins/filter_meshing/meshfilter.h
+++ b/src/meshlabplugins/filter_meshing/meshfilter.h
@@ -24,13 +24,13 @@
#ifndef EXTRAFILTERSPLUGIN_H
#define EXTRAFILTERSPLUGIN_H
-#include
+#include
-class ExtraMeshFilterPlugin : public QObject, public MeshFilterInterface
+class ExtraMeshFilterPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
enum RefPlane { REF_CENTER,REF_MIN,REF_ORIG};
diff --git a/src/meshlabplugins/filter_mls/mlsplugin.cpp b/src/meshlabplugins/filter_mls/mlsplugin.cpp
index ff9735efa..58c75d44d 100644
--- a/src/meshlabplugins/filter_mls/mlsplugin.cpp
+++ b/src/meshlabplugins/filter_mls/mlsplugin.cpp
@@ -99,24 +99,24 @@ QString MlsPlugin::pluginName() const
return QString("Filter Unknown");
}
- MeshFilterInterface::FilterClass MlsPlugin::getClass(const QAction *a) const
+ FilterPluginInterface::FilterClass MlsPlugin::getClass(const QAction *a) const
{
int filterId = ID(a);
switch(filterId) {
case FP_APSS_PROJECTION :
- case FP_RIMLS_PROJECTION : return FilterClass(MeshFilterInterface::PointSet + MeshFilterInterface::Smoothing);
+ case FP_RIMLS_PROJECTION : return FilterClass(FilterPluginInterface::PointSet + FilterPluginInterface::Smoothing);
case FP_APSS_AFRONT :
case FP_RIMLS_AFRONT :
case FP_APSS_MCUBE :
- case FP_RIMLS_MCUBE : return FilterClass(MeshFilterInterface::PointSet | MeshFilterInterface::Remeshing);
+ case FP_RIMLS_MCUBE : return FilterClass(FilterPluginInterface::PointSet | FilterPluginInterface::Remeshing);
case FP_APSS_COLORIZE :
- case FP_RIMLS_COLORIZE : return FilterClass(MeshFilterInterface::PointSet | MeshFilterInterface::VertexColoring);
- case FP_RADIUS_FROM_DENSITY : return MeshFilterInterface::PointSet;
- case FP_SELECT_SMALL_COMPONENTS : return MeshFilterInterface::Selection;
+ case FP_RIMLS_COLORIZE : return FilterClass(FilterPluginInterface::PointSet | FilterPluginInterface::VertexColoring);
+ case FP_RADIUS_FROM_DENSITY : return FilterPluginInterface::PointSet;
+ case FP_SELECT_SMALL_COMPONENTS : return FilterPluginInterface::Selection;
}
assert(0);
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
// Info() must return the longer string describing each filtering action
diff --git a/src/meshlabplugins/filter_mls/mlsplugin.h b/src/meshlabplugins/filter_mls/mlsplugin.h
index 1fc27fc88..80a41a297 100644
--- a/src/meshlabplugins/filter_mls/mlsplugin.h
+++ b/src/meshlabplugins/filter_mls/mlsplugin.h
@@ -26,13 +26,13 @@
#include
-#include
+#include
-class MlsPlugin : public QObject, public MeshFilterInterface
+class MlsPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
diff --git a/src/meshlabplugins/filter_mutualglobal/filter_mutualglobal.cpp b/src/meshlabplugins/filter_mutualglobal/filter_mutualglobal.cpp
index f4b613e18..4f5425a3f 100644
--- a/src/meshlabplugins/filter_mutualglobal/filter_mutualglobal.cpp
+++ b/src/meshlabplugins/filter_mutualglobal/filter_mutualglobal.cpp
@@ -88,10 +88,10 @@ FilterMutualGlobal::FilterClass FilterMutualGlobal::getClass(const QAction *a) c
{
switch(ID(a))
{
- case FP_IMAGE_GLOBALIGN : return MeshFilterInterface::Camera;
+ case FP_IMAGE_GLOBALIGN : return FilterPluginInterface::Camera;
default : assert(0);
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
// This function define the needed parameters for each filter. Return true if the filter has some parameters
diff --git a/src/meshlabplugins/filter_mutualglobal/filter_mutualglobal.h b/src/meshlabplugins/filter_mutualglobal/filter_mutualglobal.h
index c29bff6d8..d7747665e 100644
--- a/src/meshlabplugins/filter_mutualglobal/filter_mutualglobal.h
+++ b/src/meshlabplugins/filter_mutualglobal/filter_mutualglobal.h
@@ -36,14 +36,14 @@ add sampleplugins
#include
-#include
+#include
#include "alignset.h"
-class FilterMutualGlobal : public QObject, public MeshFilterInterface
+class FilterMutualGlobal : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum { FP_IMAGE_GLOBALIGN} ;
diff --git a/src/meshlabplugins/filter_mutualinfo/filter_mutualinfo.cpp b/src/meshlabplugins/filter_mutualinfo/filter_mutualinfo.cpp
index ea7367b30..2944d9f59 100644
--- a/src/meshlabplugins/filter_mutualinfo/filter_mutualinfo.cpp
+++ b/src/meshlabplugins/filter_mutualinfo/filter_mutualinfo.cpp
@@ -73,14 +73,14 @@ FilterMutualInfoPlugin::FilterClass FilterMutualInfoPlugin::getClass(const QActi
{
switch(ID(a)) {
case FP_IMAGE_MUTUALINFO:
- return MeshFilterInterface::Camera;
+ return FilterPluginInterface::Camera;
default :
assert(0);
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
}
-MeshFilterInterface::FILTER_ARITY FilterMutualInfoPlugin::filterArity(const QAction*) const
+FilterPluginInterface::FILTER_ARITY FilterMutualInfoPlugin::filterArity(const QAction*) const
{
return SINGLE_MESH;
}
diff --git a/src/meshlabplugins/filter_mutualinfo/filter_mutualinfo.h b/src/meshlabplugins/filter_mutualinfo/filter_mutualinfo.h
index f4f0d807c..a060c8df7 100644
--- a/src/meshlabplugins/filter_mutualinfo/filter_mutualinfo.h
+++ b/src/meshlabplugins/filter_mutualinfo/filter_mutualinfo.h
@@ -26,14 +26,14 @@
#include
-#include
+#include
#include "alignset.h"
-class FilterMutualInfoPlugin : public QObject, public MeshFilterInterface
+class FilterMutualInfoPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
diff --git a/src/meshlabplugins/filter_plymc/filter_plymc.cpp b/src/meshlabplugins/filter_plymc/filter_plymc.cpp
index 7e9c52314..00cbc391f 100644
--- a/src/meshlabplugins/filter_plymc/filter_plymc.cpp
+++ b/src/meshlabplugins/filter_plymc/filter_plymc.cpp
@@ -26,6 +26,7 @@
#include
#include
#include
+#include
using namespace vcg;
@@ -86,11 +87,11 @@ QString PlyMCPlugin::pluginName() const
{
switch(ID(a))
{
- case FP_PLYMC : return MeshFilterInterface::Remeshing;
- case FP_MC_SIMPLIFY : return MeshFilterInterface::Remeshing;
+ case FP_PLYMC : return FilterPluginInterface::Remeshing;
+ case FP_MC_SIMPLIFY : return FilterPluginInterface::Remeshing;
default : assert(0);
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
// This function define the needed parameters for each filter. Return true if the filter has some parameters
@@ -246,13 +247,13 @@ bool PlyMCPlugin::applyFilter(const QAction *filter, MeshDocument &md, const Ric
return true;
}
-MeshFilterInterface::FILTER_ARITY PlyMCPlugin::filterArity(const QAction * filter ) const
+FilterPluginInterface::FILTER_ARITY PlyMCPlugin::filterArity(const QAction * filter ) const
{
switch(ID(filter))
{
- case FP_PLYMC : return MeshFilterInterface::VARIABLE;
- case FP_MC_SIMPLIFY : return MeshFilterInterface::SINGLE_MESH;
- default: return MeshFilterInterface::NONE;
+ case FP_PLYMC : return FilterPluginInterface::VARIABLE;
+ case FP_MC_SIMPLIFY : return FilterPluginInterface::SINGLE_MESH;
+ default: return FilterPluginInterface::NONE;
}
}
diff --git a/src/meshlabplugins/filter_plymc/filter_plymc.h b/src/meshlabplugins/filter_plymc/filter_plymc.h
index 300ab9ea3..6f406e2c1 100644
--- a/src/meshlabplugins/filter_plymc/filter_plymc.h
+++ b/src/meshlabplugins/filter_plymc/filter_plymc.h
@@ -24,13 +24,13 @@
#ifndef _FILTER_PLYMC_H_
#define _FILTER_PLYMC_H_
-#include
+#include
-class PlyMCPlugin : public QObject, public MeshFilterInterface
+class PlyMCPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum {
@@ -46,7 +46,7 @@ public:
virtual void initParameterList(const QAction*, MeshModel &/*m*/, RichParameterList & /*parent*/);
virtual bool applyFilter(const QAction* filter, MeshDocument &md, const RichParameterList & /*parent*/, vcg::CallBackPos * cb) ;
FilterClass getClass(const QAction* a) const;
- MeshFilterInterface::FILTER_ARITY filterArity(const QAction* filter) const;
+ FilterPluginInterface::FILTER_ARITY filterArity(const QAction* filter) const;
int postCondition(const QAction *filter) const;
};
diff --git a/src/meshlabplugins/filter_qhull/filter_qhull.cpp b/src/meshlabplugins/filter_qhull/filter_qhull.cpp
index b35505381..f06f4e794 100644
--- a/src/meshlabplugins/filter_qhull/filter_qhull.cpp
+++ b/src/meshlabplugins/filter_qhull/filter_qhull.cpp
@@ -120,9 +120,9 @@ QString QhullPlugin::pluginName() const
case FP_QHULL_DELAUNAY_TRIANGULATION :
case FP_QHULL_VORONOI_FILTERING :
case FP_QHULL_ALPHA_COMPLEX_AND_SHAPE:
- return FilterClass (MeshFilterInterface::Remeshing) ;
+ return FilterClass (FilterPluginInterface::Remeshing) ;
case FP_QHULL_VISIBLE_POINTS:
- return FilterClass (MeshFilterInterface::Selection + MeshFilterInterface::PointSet);
+ return FilterClass (FilterPluginInterface::Selection + FilterPluginInterface::PointSet);
default : assert(0);
}
return FilterClass(0);
diff --git a/src/meshlabplugins/filter_qhull/filter_qhull.h b/src/meshlabplugins/filter_qhull/filter_qhull.h
index 0f5cc92d0..35bea5802 100644
--- a/src/meshlabplugins/filter_qhull/filter_qhull.h
+++ b/src/meshlabplugins/filter_qhull/filter_qhull.h
@@ -29,13 +29,13 @@ History
#define QHULLFILTERSPLUGIN_H
#include
-#include
+#include
-class QhullPlugin : public QObject, public MeshFilterInterface
+class QhullPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
diff --git a/src/meshlabplugins/filter_quality/filterqualitymapper.cpp b/src/meshlabplugins/filter_quality/filterqualitymapper.cpp
index 2b8038489..911f82538 100644
--- a/src/meshlabplugins/filter_quality/filterqualitymapper.cpp
+++ b/src/meshlabplugins/filter_quality/filterqualitymapper.cpp
@@ -69,12 +69,12 @@ QString QualityMapperFilter::pluginName() const
return QString("");
}
- MeshFilterInterface::FilterClass QualityMapperFilter::getClass(const QAction *a) const
+ FilterPluginInterface::FilterClass QualityMapperFilter::getClass(const QAction *a) const
{
switch(ID(a))
{
- case FP_QUALITY_MAPPER : return MeshFilterInterface::Quality;
- default : assert(0); return MeshFilterInterface::Generic;
+ case FP_QUALITY_MAPPER : return FilterPluginInterface::Quality;
+ default : assert(0); return FilterPluginInterface::Generic;
}
}
diff --git a/src/meshlabplugins/filter_quality/filterqualitymapper.h b/src/meshlabplugins/filter_quality/filterqualitymapper.h
index 65161fab9..71ea0ab5d 100644
--- a/src/meshlabplugins/filter_quality/filterqualitymapper.h
+++ b/src/meshlabplugins/filter_quality/filterqualitymapper.h
@@ -32,7 +32,7 @@ FIRST RELEASE
#include
-#include
+#include
#include "../edit_quality/common/transferfunction.h"
#include // for ComputePerVertexQualityMinMax
@@ -55,11 +55,11 @@ public:
};
-class QualityMapperFilter : public QObject, public MeshFilterInterface
+class QualityMapperFilter : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
private:
Frange _meshMinMaxQuality;
diff --git a/src/meshlabplugins/filter_sample/filter_sample.cpp b/src/meshlabplugins/filter_sample/filter_sample.cpp
index c43a2ebaa..7a0003ae6 100644
--- a/src/meshlabplugins/filter_sample/filter_sample.cpp
+++ b/src/meshlabplugins/filter_sample/filter_sample.cpp
@@ -87,10 +87,10 @@ FilterSamplePlugin::FilterClass FilterSamplePlugin::getClass(const QAction *a) c
{
switch(ID(a)) {
case FP_MOVE_VERTEX :
- return MeshFilterInterface::Smoothing;
+ return FilterPluginInterface::Smoothing;
default :
assert(0);
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
}
@@ -98,7 +98,7 @@ FilterSamplePlugin::FilterClass FilterSamplePlugin::getClass(const QAction *a) c
* @brief FilterSamplePlugin::filterArity
* @return
*/
-MeshFilterInterface::FILTER_ARITY FilterSamplePlugin::filterArity(const QAction*) const
+FilterPluginInterface::FILTER_ARITY FilterSamplePlugin::filterArity(const QAction*) const
{
return SINGLE_MESH;
}
diff --git a/src/meshlabplugins/filter_sample/filter_sample.h b/src/meshlabplugins/filter_sample/filter_sample.h
index dddf78ad0..1b55b1ecf 100644
--- a/src/meshlabplugins/filter_sample/filter_sample.h
+++ b/src/meshlabplugins/filter_sample/filter_sample.h
@@ -39,13 +39,13 @@ add sampleplugins
#ifndef FILTERSAMPLE_PLUGIN_H
#define FILTERSAMPLE_PLUGIN_H
-#include
+#include
-class FilterSamplePlugin : public QObject, public MeshFilterInterface
+class FilterSamplePlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum { FP_MOVE_VERTEX } ;
diff --git a/src/meshlabplugins/filter_sample_dyn/filter_sample_dyn.cpp b/src/meshlabplugins/filter_sample_dyn/filter_sample_dyn.cpp
index ee1b0b749..93c1688e7 100644
--- a/src/meshlabplugins/filter_sample_dyn/filter_sample_dyn.cpp
+++ b/src/meshlabplugins/filter_sample_dyn/filter_sample_dyn.cpp
@@ -72,7 +72,7 @@ QString ExtraSampleDynPlugin::filterName(FilterIDType filterId) const
// The FilterClass describes in which generic class of filters it fits.
// This choice affect the submenu in which each filter will be placed
// In this case this sample belong to the class of filters that change the vertex colors
- MeshFilterInterface::FilterClass ExtraSampleDynPlugin::getClass(const QAction *) const { return MeshFilterInterface::VertexColoring; }
+ FilterPluginInterface::FilterClass ExtraSampleDynPlugin::getClass(const QAction *) const { return FilterPluginInterface::VertexColoring; }
// This function define the needed parameters for each filter. Return true if the filter has some parameters
// it is called every time, so you can set the default value of parameters according to the mesh
diff --git a/src/meshlabplugins/filter_sample_dyn/filter_sample_dyn.h b/src/meshlabplugins/filter_sample_dyn/filter_sample_dyn.h
index 2db3df4e6..f67c0c806 100644
--- a/src/meshlabplugins/filter_sample_dyn/filter_sample_dyn.h
+++ b/src/meshlabplugins/filter_sample_dyn/filter_sample_dyn.h
@@ -26,13 +26,13 @@
#include
-#include
+#include
-class ExtraSampleDynPlugin : public QObject, public MeshFilterInterface
+class ExtraSampleDynPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum { FP_VERTEX_COLOR_NOISE } ;
diff --git a/src/meshlabplugins/filter_sample_gpu/filter_sample_gpu.cpp b/src/meshlabplugins/filter_sample_gpu/filter_sample_gpu.cpp
index 53e991e3e..fb1b12ab9 100644
--- a/src/meshlabplugins/filter_sample_gpu/filter_sample_gpu.cpp
+++ b/src/meshlabplugins/filter_sample_gpu/filter_sample_gpu.cpp
@@ -74,10 +74,10 @@ ExtraSampleGPUPlugin::FilterClass ExtraSampleGPUPlugin::getClass(const QAction *
{
switch(ID(a))
{
- case FP_GPU_EXAMPLE: return MeshFilterInterface::RasterLayer; //should be generic, but better avoid it
+ case FP_GPU_EXAMPLE: return FilterPluginInterface::RasterLayer; //should be generic, but better avoid it
default : assert(0);
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
// This function define the needed parameters for each filter. Return true if the filter has some parameters
diff --git a/src/meshlabplugins/filter_sample_gpu/filter_sample_gpu.h b/src/meshlabplugins/filter_sample_gpu/filter_sample_gpu.h
index b35f42850..ce5a768b4 100644
--- a/src/meshlabplugins/filter_sample_gpu/filter_sample_gpu.h
+++ b/src/meshlabplugins/filter_sample_gpu/filter_sample_gpu.h
@@ -36,13 +36,13 @@ add sampleplugins
#include
-#include
+#include
-class ExtraSampleGPUPlugin : public QObject, public MeshFilterInterface
+class ExtraSampleGPUPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum { FP_GPU_EXAMPLE } ;
diff --git a/src/meshlabplugins/filter_sampling/filter_sampling.cpp b/src/meshlabplugins/filter_sampling/filter_sampling.cpp
index c63433aa2..8427cd2b7 100644
--- a/src/meshlabplugins/filter_sampling/filter_sampling.cpp
+++ b/src/meshlabplugins/filter_sampling/filter_sampling.cpp
@@ -40,6 +40,8 @@ $Log: samplefilter.cpp,v $
#include
#include
+#include
+
using namespace vcg;
using namespace std;
@@ -1356,7 +1358,7 @@ switch(ID(action))
return true;
}
-MeshFilterInterface::FilterClass FilterDocSampling::getClass(const QAction *action) const
+FilterPluginInterface::FilterClass FilterDocSampling::getClass(const QAction *action) const
{
switch(ID(action))
{
@@ -1372,8 +1374,8 @@ MeshFilterInterface::FilterClass FilterDocSampling::getClass(const QAction *acti
case FP_TEXEL_SAMPLING : return FilterDocSampling::Sampling;
case FP_UNIFORM_MESH_RESAMPLING: return FilterDocSampling::Remeshing;
case FP_DISK_COLORING:
- case FP_VORONOI_COLORING: return MeshFilterInterface::FilterClass(FilterDocSampling::Sampling | FilterDocSampling::VertexColoring);
- case FP_POINTCLOUD_SIMPLIFICATION : return MeshFilterInterface::FilterClass(FilterDocSampling::Sampling | FilterDocSampling::PointSet);
+ case FP_VORONOI_COLORING: return FilterPluginInterface::FilterClass(FilterDocSampling::Sampling | FilterDocSampling::VertexColoring);
+ case FP_POINTCLOUD_SIMPLIFICATION : return FilterPluginInterface::FilterClass(FilterDocSampling::Sampling | FilterDocSampling::PointSet);
default: assert(0);
}
return FilterClass(0);
@@ -1396,7 +1398,7 @@ int FilterDocSampling::postCondition(const QAction* a ) const
return MeshModel::MM_ALL;
}
-MeshFilterInterface::FILTER_ARITY FilterDocSampling::filterArity(const QAction * filter ) const
+FilterPluginInterface::FILTER_ARITY FilterDocSampling::filterArity(const QAction * filter ) const
{
switch(ID(filter))
{
@@ -1408,15 +1410,15 @@ MeshFilterInterface::FILTER_ARITY FilterDocSampling::filterArity(const QAction *
case FP_REGULAR_RECURSIVE_SAMPLING :
case FP_UNIFORM_MESH_RESAMPLING:
case FP_POINTCLOUD_SIMPLIFICATION :
- return MeshFilterInterface::SINGLE_MESH;
+ return FilterPluginInterface::SINGLE_MESH;
case FP_DISTANCE_REFERENCE :
case FP_HAUSDORFF_DISTANCE :
case FP_POISSONDISK_SAMPLING :
case FP_DISK_COLORING :
case FP_VORONOI_COLORING :
- return MeshFilterInterface::FIXED;
+ return FilterPluginInterface::FIXED;
}
- return MeshFilterInterface::NONE;
+ return FilterPluginInterface::NONE;
}
MESHLAB_PLUGIN_NAME_EXPORTER(FilterDocSampling)
diff --git a/src/meshlabplugins/filter_sampling/filter_sampling.h b/src/meshlabplugins/filter_sampling/filter_sampling.h
index 003c710cd..d8c264e67 100644
--- a/src/meshlabplugins/filter_sampling/filter_sampling.h
+++ b/src/meshlabplugins/filter_sampling/filter_sampling.h
@@ -23,13 +23,13 @@
#ifndef FILTERDOCSAMPLINGPLUGIN_H
#define FILTERDOCSAMPLINGPLUGIN_H
-#include
+#include
-class FilterDocSampling : public QObject, public MeshFilterInterface
+class FilterDocSampling : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum {
diff --git a/src/meshlabplugins/filter_screened_poisson/filter_screened_poisson.cpp b/src/meshlabplugins/filter_screened_poisson/filter_screened_poisson.cpp
index c9c33d300..ec1a334a5 100644
--- a/src/meshlabplugins/filter_screened_poisson/filter_screened_poisson.cpp
+++ b/src/meshlabplugins/filter_screened_poisson/filter_screened_poisson.cpp
@@ -26,6 +26,10 @@
#include
#endif
+#include
+#include
+#include
+
#include "filter_screened_poisson.h"
#include "poisson_utils.h"
@@ -77,14 +81,14 @@ QString FilterScreenedPoissonPlugin::filterInfo(FilterIDType filter) const
}
}
-MeshFilterInterface::FilterClass FilterScreenedPoissonPlugin::getClass(const QAction* a) const
+FilterPluginInterface::FilterClass FilterScreenedPoissonPlugin::getClass(const QAction* a) const
{
if (ID(a) == FP_SCREENED_POISSON){
- return FilterScreenedPoissonPlugin::FilterClass(MeshFilterInterface::Remeshing);
+ return FilterScreenedPoissonPlugin::FilterClass(FilterPluginInterface::Remeshing);
}
else {
assert(0);
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
}
@@ -223,7 +227,7 @@ int FilterScreenedPoissonPlugin::postCondition(const QAction* filter) const
}
-MeshFilterInterface::FILTER_ARITY FilterScreenedPoissonPlugin::filterArity(const QAction*) const
+FilterPluginInterface::FILTER_ARITY FilterScreenedPoissonPlugin::filterArity(const QAction*) const
{
return VARIABLE;
}
diff --git a/src/meshlabplugins/filter_screened_poisson/filter_screened_poisson.h b/src/meshlabplugins/filter_screened_poisson/filter_screened_poisson.h
index 23157029d..0f68d14c6 100644
--- a/src/meshlabplugins/filter_screened_poisson/filter_screened_poisson.h
+++ b/src/meshlabplugins/filter_screened_poisson/filter_screened_poisson.h
@@ -24,13 +24,13 @@
#ifndef SAMPLEFILTERSPLUGIN_H
#define SAMPLEFILTERSPLUGIN_H
-#include
+#include
-class FilterScreenedPoissonPlugin : public QObject, public MeshFilterInterface
+class FilterScreenedPoissonPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum {
diff --git a/src/meshlabplugins/filter_sdfgpu/filter_sdfgpu.cpp b/src/meshlabplugins/filter_sdfgpu/filter_sdfgpu.cpp
index b18343723..9ad25d5a7 100644
--- a/src/meshlabplugins/filter_sdfgpu/filter_sdfgpu.cpp
+++ b/src/meshlabplugins/filter_sdfgpu/filter_sdfgpu.cpp
@@ -1095,9 +1095,9 @@ void SdfGpuPlugin::TraceRay(int peelingIteration,const Point3f& dir, MeshModel*
checkGLError::debugInfo("Error during depth peeling");
}
-MeshFilterInterface::FILTER_ARITY SdfGpuPlugin::filterArity(const QAction *) const
+FilterPluginInterface::FILTER_ARITY SdfGpuPlugin::filterArity(const QAction *) const
{
- return MeshFilterInterface::SINGLE_MESH;
+ return FilterPluginInterface::SINGLE_MESH;
}
MESHLAB_PLUGIN_NAME_EXPORTER(SdfGpuPlugin)
diff --git a/src/meshlabplugins/filter_sdfgpu/filter_sdfgpu.h b/src/meshlabplugins/filter_sdfgpu/filter_sdfgpu.h
index 3d209406e..97e9a29e7 100644
--- a/src/meshlabplugins/filter_sdfgpu/filter_sdfgpu.h
+++ b/src/meshlabplugins/filter_sdfgpu/filter_sdfgpu.h
@@ -3,7 +3,7 @@
#include
-#include
+#include
#include
#include
@@ -11,11 +11,11 @@
enum ONPRIMITIVE{ON_VERTICES=0, ON_FACES=1};
-class SdfGpuPlugin : public QObject, public MeshFilterInterface
+class SdfGpuPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
@@ -31,7 +31,7 @@ public:
FilterClass getClass(const QAction *) const
{
- return MeshFilterInterface::VertexColoring;
+ return FilterPluginInterface::VertexColoring;
}
FILTER_ARITY filterArity(const QAction* act) const;
diff --git a/src/meshlabplugins/filter_sdfgpu/filterinterface.h b/src/meshlabplugins/filter_sdfgpu/filterinterface.h
index 1bcbe8d8c..93bfc311d 100644
--- a/src/meshlabplugins/filter_sdfgpu/filterinterface.h
+++ b/src/meshlabplugins/filter_sdfgpu/filterinterface.h
@@ -36,7 +36,7 @@
* Q_EXPORT_PLUGIN(SdfPlugin)
* \endcode
*/
-class SingleMeshFilterInterface : public QObject, public MeshFilterInterface{
+class SingleMeshFilterInterface : public QObject, public FilterPluginInterface{
public:
/**
@@ -80,7 +80,7 @@ public:
* plugin to the bottom of the list.
*/
virtual FilterClass getClass() const{
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
/**
diff --git a/src/meshlabplugins/filter_select/meshselect.cpp b/src/meshlabplugins/filter_select/meshselect.cpp
index 6e1ab80ca..93b885002 100644
--- a/src/meshlabplugins/filter_select/meshselect.cpp
+++ b/src/meshlabplugins/filter_select/meshselect.cpp
@@ -29,6 +29,8 @@
#include
#include
+#include
+
using namespace vcg;
// ERROR CHECKING UTILITY
@@ -649,18 +651,18 @@ bool SelectionFilterPlugin::applyFilter(const QAction *action, MeshDocument &md,
return true;
}
-MeshFilterInterface::FilterClass SelectionFilterPlugin::getClass(const QAction *action) const
+FilterPluginInterface::FilterClass SelectionFilterPlugin::getClass(const QAction *action) const
{
switch(ID(action))
{
- case CP_SELFINTERSECT_SELECT: return FilterClass(MeshFilterInterface::Selection + MeshFilterInterface::Cleaning);
+ case CP_SELFINTERSECT_SELECT: return FilterClass(FilterPluginInterface::Selection + FilterPluginInterface::Cleaning);
- case CP_SELECT_TEXBORDER : return FilterClass(MeshFilterInterface::Selection + MeshFilterInterface::Texture);
+ case CP_SELECT_TEXBORDER : return FilterClass(FilterPluginInterface::Selection + FilterPluginInterface::Texture);
case FP_SELECT_BY_FACE_QUALITY :
- case FP_SELECT_BY_VERT_QUALITY : return FilterClass(MeshFilterInterface::Selection + MeshFilterInterface::Quality);
+ case FP_SELECT_BY_VERT_QUALITY : return FilterClass(FilterPluginInterface::Selection + FilterPluginInterface::Quality);
- case FP_SELECTBYANGLE : return MeshFilterInterface::FilterClass(MeshFilterInterface::RangeMap + MeshFilterInterface::Selection);
+ case FP_SELECTBYANGLE : return FilterPluginInterface::FilterClass(FilterPluginInterface::RangeMap + FilterPluginInterface::Selection);
case FP_SELECT_ALL :
case FP_SELECT_NONE :
@@ -681,9 +683,9 @@ MeshFilterInterface::FilterClass SelectionFilterPlugin::getClass(const QAction *
case FP_SELECT_OUTLIER:
case FP_SELECT_BY_COLOR:
case CP_SELECT_NON_MANIFOLD_VERTEX:
- case CP_SELECT_NON_MANIFOLD_FACE: return FilterClass(MeshFilterInterface::Selection);
+ case CP_SELECT_NON_MANIFOLD_FACE: return FilterClass(FilterPluginInterface::Selection);
}
- return MeshFilterInterface::Selection;
+ return FilterPluginInterface::Selection;
}
int SelectionFilterPlugin::getRequirements(const QAction *action)
diff --git a/src/meshlabplugins/filter_select/meshselect.h b/src/meshlabplugins/filter_select/meshselect.h
index a199ee96c..0727895fd 100644
--- a/src/meshlabplugins/filter_select/meshselect.h
+++ b/src/meshlabplugins/filter_select/meshselect.h
@@ -25,14 +25,14 @@
#define FILTER_SELECT_H
#include
-#include
+#include
-class SelectionFilterPlugin : public QObject, public MeshFilterInterface
+class SelectionFilterPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
/* naming convention :
diff --git a/src/meshlabplugins/filter_sketchfab/filter_sketchfab.cpp b/src/meshlabplugins/filter_sketchfab/filter_sketchfab.cpp
index 54e05cbec..2725af957 100644
--- a/src/meshlabplugins/filter_sketchfab/filter_sketchfab.cpp
+++ b/src/meshlabplugins/filter_sketchfab/filter_sketchfab.cpp
@@ -26,6 +26,9 @@
#include
#include
#include
+#include
+#include
+#include
#include
#include "miniz.h"
@@ -68,14 +71,14 @@ FilterSketchFabPlugin::FilterClass FilterSketchFabPlugin::getClass(const QAction
{
switch(ID(a)) {
case FP_SKETCHFAB :
- return MeshFilterInterface::Smoothing;
+ return FilterPluginInterface::Smoothing;
default :
assert(0);
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
}
-MeshFilterInterface::FILTER_ARITY FilterSketchFabPlugin::filterArity(const QAction* a) const
+FilterPluginInterface::FILTER_ARITY FilterSketchFabPlugin::filterArity(const QAction* a) const
{
switch(ID(a)) {
case FP_SKETCHFAB :
diff --git a/src/meshlabplugins/filter_sketchfab/filter_sketchfab.h b/src/meshlabplugins/filter_sketchfab/filter_sketchfab.h
index 75b74bef1..59d84bb00 100644
--- a/src/meshlabplugins/filter_sketchfab/filter_sketchfab.h
+++ b/src/meshlabplugins/filter_sketchfab/filter_sketchfab.h
@@ -24,14 +24,14 @@
#ifndef FILTERSKETCHFAB_H
#define FILTERSKETCHFAB_H
-#include
+#include
#include
-class FilterSketchFabPlugin : public QObject, public MeshFilterInterface
+class FilterSketchFabPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum { FP_SKETCHFAB } ;
diff --git a/src/meshlabplugins/filter_ssynth/filter_ssynth.cpp b/src/meshlabplugins/filter_ssynth/filter_ssynth.cpp
index 6b612cbe5..b3579e1ef 100644
--- a/src/meshlabplugins/filter_ssynth/filter_ssynth.cpp
+++ b/src/meshlabplugins/filter_ssynth/filter_ssynth.cpp
@@ -153,9 +153,9 @@ int FilterSSynth::postCondition(const QAction* /*filter*/) const
return MeshModel::MM_NONE;
}
-MeshFilterInterface::FilterClass FilterSSynth::getClass(const QAction */*filter*/) const
+FilterPluginInterface::FilterClass FilterSSynth::getClass(const QAction */*filter*/) const
{
- return MeshFilterInterface::MeshCreation;
+ return FilterPluginInterface::MeshCreation;
}
QList FilterSSynth::importFormats() const
diff --git a/src/meshlabplugins/filter_ssynth/filter_ssynth.h b/src/meshlabplugins/filter_ssynth/filter_ssynth.h
index 6d2ba3991..061304a9a 100644
--- a/src/meshlabplugins/filter_ssynth/filter_ssynth.h
+++ b/src/meshlabplugins/filter_ssynth/filter_ssynth.h
@@ -27,14 +27,13 @@
#include
-#include
-#include
+#include
#include
-class FilterSSynth : public QObject,public IOPluginInterface, public MeshFilterInterface{
+class FilterSSynth : public QObject,public IOPluginInterface, public FilterPluginInterface{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface IOPluginInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface IOPluginInterface)
public:
enum {CR_SSYNTH} ;
@@ -58,7 +57,7 @@ public:
void initPreOpenParameter(const QString &formatName, const QString &filename, RichParameterList &parlst);
bool open(const QString &formatName, const QString &fileName, MeshModel &m, int& mask, const RichParameterList & par, vcg::CallBackPos *cb=0, QWidget *parent=0);
bool save(const QString &formatName, const QString &fileName, MeshModel &m, const int mask, const RichParameterList &, vcg::CallBackPos *cb, QWidget *parent);
- MeshFilterInterface::FILTER_ARITY filterArity(const QAction *) const {return NONE;}
+ FilterPluginInterface::FILTER_ARITY filterArity(const QAction *) const {return NONE;}
private:
QString ssynth(QString grammar,int maxdepth,int seed,vcg::CallBackPos *cb);
QString GetTemplate(int sphereres);
diff --git a/src/meshlabplugins/filter_texture/filter_texture.cpp b/src/meshlabplugins/filter_texture/filter_texture.cpp
index ca97ea3ee..3de6cae90 100644
--- a/src/meshlabplugins/filter_texture/filter_texture.cpp
+++ b/src/meshlabplugins/filter_texture/filter_texture.cpp
@@ -165,11 +165,11 @@ FilterTexturePlugin::FilterClass FilterTexturePlugin::getClass(const QAction *a)
case FP_PLANAR_MAPPING :
case FP_SET_TEXTURE :
case FP_COLOR_TO_TEXTURE :
- case FP_TRANSFER_TO_TEXTURE : return MeshFilterInterface::Texture;
- case FP_TEX_TO_VCOLOR_TRANSFER : return FilterClass(MeshFilterInterface::VertexColoring + MeshFilterInterface::Texture);
+ case FP_TRANSFER_TO_TEXTURE : return FilterPluginInterface::Texture;
+ case FP_TEX_TO_VCOLOR_TRANSFER : return FilterClass(FilterPluginInterface::VertexColoring + FilterPluginInterface::Texture);
default : assert(0);
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
static QString extractFilenameWOExt(MeshModel* mm)
@@ -1109,7 +1109,7 @@ bool FilterTexturePlugin::applyFilter(const QAction *filter, MeshDocument &md, c
return true;
}
-MeshFilterInterface::FILTER_ARITY FilterTexturePlugin::filterArity(const QAction * filter ) const
+FilterPluginInterface::FILTER_ARITY FilterTexturePlugin::filterArity(const QAction * filter ) const
{
switch(ID(filter))
{
@@ -1120,12 +1120,12 @@ MeshFilterInterface::FILTER_ARITY FilterTexturePlugin::filterArity(const QAction
case FP_PLANAR_MAPPING :
case FP_SET_TEXTURE :
case FP_COLOR_TO_TEXTURE :
- return MeshFilterInterface::SINGLE_MESH;
+ return FilterPluginInterface::SINGLE_MESH;
case FP_TRANSFER_TO_TEXTURE :
case FP_TEX_TO_VCOLOR_TRANSFER :
- return MeshFilterInterface::FIXED;
+ return FilterPluginInterface::FIXED;
}
- return MeshFilterInterface::NONE;
+ return FilterPluginInterface::NONE;
}
diff --git a/src/meshlabplugins/filter_texture/filter_texture.h b/src/meshlabplugins/filter_texture/filter_texture.h
index 2ba11707a..f1ed10b7a 100644
--- a/src/meshlabplugins/filter_texture/filter_texture.h
+++ b/src/meshlabplugins/filter_texture/filter_texture.h
@@ -28,17 +28,17 @@
#include
#include
-#include
+#include
#include
#include
#include
#include
-class FilterTexturePlugin : public QObject, public MeshFilterInterface
+class FilterTexturePlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum {
diff --git a/src/meshlabplugins/filter_trioptimize/filter_trioptimize.cpp b/src/meshlabplugins/filter_trioptimize/filter_trioptimize.cpp
index 9531001d4..d1ebc5c7e 100644
--- a/src/meshlabplugins/filter_trioptimize/filter_trioptimize.cpp
+++ b/src/meshlabplugins/filter_trioptimize/filter_trioptimize.cpp
@@ -174,11 +174,11 @@ QString TriOptimizePlugin::pluginName() const
TriOptimizePlugin::FilterClass TriOptimizePlugin::getClass(const QAction *action) const
{
switch(ID(action)) {
- case FP_PLANAR_EDGE_FLIP: return MeshFilterInterface::Remeshing;
- case FP_CURVATURE_EDGE_FLIP: return MeshFilterInterface::Remeshing;
- case FP_NEAR_LAPLACIAN_SMOOTH: return MeshFilterInterface::Smoothing;
+ case FP_PLANAR_EDGE_FLIP: return FilterPluginInterface::Remeshing;
+ case FP_CURVATURE_EDGE_FLIP: return FilterPluginInterface::Remeshing;
+ case FP_NEAR_LAPLACIAN_SMOOTH: return FilterPluginInterface::Smoothing;
}
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
int TriOptimizePlugin::postCondition(const QAction *a) const
diff --git a/src/meshlabplugins/filter_trioptimize/filter_trioptimize.h b/src/meshlabplugins/filter_trioptimize/filter_trioptimize.h
index 26da938d9..a9ea5e7d6 100644
--- a/src/meshlabplugins/filter_trioptimize/filter_trioptimize.h
+++ b/src/meshlabplugins/filter_trioptimize/filter_trioptimize.h
@@ -25,13 +25,13 @@
#define TRIOPTIMIZEFILTERSPLUGIN_H
#include
-#include
+#include
-class TriOptimizePlugin : public QObject, public MeshFilterInterface
+class TriOptimizePlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum {
diff --git a/src/meshlabplugins/filter_unsharp/filter_unsharp.cpp b/src/meshlabplugins/filter_unsharp/filter_unsharp.cpp
index f36ebc3c9..d1a8a4cbf 100644
--- a/src/meshlabplugins/filter_unsharp/filter_unsharp.cpp
+++ b/src/meshlabplugins/filter_unsharp/filter_unsharp.cpp
@@ -186,7 +186,7 @@ QString FilterUnsharp::filterInfo(FilterIDType filterId) const
switch(ID(a))
{
case FP_CREASE_CUT :
- return MeshFilterInterface::FilterClass( MeshFilterInterface::Normal | MeshFilterInterface::Remeshing);
+ return FilterPluginInterface::FilterClass( FilterPluginInterface::Normal | FilterPluginInterface::Remeshing);
case FP_SD_LAPLACIAN_SMOOTH:
case FP_HC_LAPLACIAN_SMOOTH:
case FP_LAPLACIAN_SMOOTH:
@@ -200,20 +200,20 @@ QString FilterUnsharp::filterInfo(FilterIDType filterId) const
case FP_UNSHARP_GEOMETRY:
case FP_UNSHARP_QUALITY:
case FP_LINEAR_MORPH :
- return MeshFilterInterface::Smoothing;
+ return FilterPluginInterface::Smoothing;
case FP_UNSHARP_VERTEX_COLOR:
- return MeshFilterInterface::FilterClass( MeshFilterInterface::Smoothing | MeshFilterInterface::VertexColoring);
+ return FilterPluginInterface::FilterClass( FilterPluginInterface::Smoothing | FilterPluginInterface::VertexColoring);
case FP_RECOMPUTE_FACE_NORMAL :
case FP_RECOMPUTE_QUADFACE_NORMAL :
case FP_RECOMPUTE_VERTEX_NORMAL :
case FP_FACE_NORMAL_NORMALIZE:
case FP_VERTEX_NORMAL_NORMALIZE:
- return MeshFilterInterface::Normal;
- case FP_SCALAR_HARMONIC_FIELD: return MeshFilterInterface::Remeshing;
+ return FilterPluginInterface::Normal;
+ case FP_SCALAR_HARMONIC_FIELD: return FilterPluginInterface::Remeshing;
- default : return MeshFilterInterface::Generic;
+ default : return FilterPluginInterface::Generic;
}
}
int FilterUnsharp::getPreConditions(const QAction *a) const
@@ -785,7 +785,7 @@ bool FilterUnsharp::applyFilter(const QAction *filter, MeshDocument &md, const R
return true;
}
-MeshFilterInterface::FILTER_ARITY FilterUnsharp::filterArity(const QAction * filter ) const
+FilterPluginInterface::FILTER_ARITY FilterUnsharp::filterArity(const QAction * filter ) const
{
switch(ID(filter))
{
@@ -809,11 +809,11 @@ MeshFilterInterface::FILTER_ARITY FilterUnsharp::filterArity(const QAction * fil
case FP_RECOMPUTE_FACE_NORMAL:
case FP_RECOMPUTE_QUADFACE_NORMAL:
case FP_SCALAR_HARMONIC_FIELD:
- return MeshFilterInterface::SINGLE_MESH;
+ return FilterPluginInterface::SINGLE_MESH;
case FP_LINEAR_MORPH :
- return MeshFilterInterface::FIXED;
+ return FilterPluginInterface::FIXED;
}
- return MeshFilterInterface::NONE;
+ return FilterPluginInterface::NONE;
}
diff --git a/src/meshlabplugins/filter_unsharp/filter_unsharp.h b/src/meshlabplugins/filter_unsharp/filter_unsharp.h
index 2f42176cc..ee03de328 100644
--- a/src/meshlabplugins/filter_unsharp/filter_unsharp.h
+++ b/src/meshlabplugins/filter_unsharp/filter_unsharp.h
@@ -24,14 +24,14 @@
#define FilterUnsharp_PLUGIN_H
#include
-#include
+#include
-class FilterUnsharp : public QObject, public MeshFilterInterface
+class FilterUnsharp : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
/* naming convention :
diff --git a/src/meshlabplugins/filter_voronoi/filter_voronoi.cpp b/src/meshlabplugins/filter_voronoi/filter_voronoi.cpp
index 9ff3050e3..4bacd9540 100644
--- a/src/meshlabplugins/filter_voronoi/filter_voronoi.cpp
+++ b/src/meshlabplugins/filter_voronoi/filter_voronoi.cpp
@@ -101,20 +101,20 @@ FilterVoronoiPlugin::FilterClass FilterVoronoiPlugin::getClass(const QAction* a)
case VORONOI_SAMPLING :
case VOLUME_SAMPLING:
case VORONOI_SCAFFOLDING:
- return MeshFilterInterface::Sampling;
+ return FilterPluginInterface::Sampling;
case BUILD_SHELL:
- return MeshFilterInterface::Remeshing;
+ return FilterPluginInterface::Remeshing;
case CROSS_FIELD_CREATION:
- return MeshFilterInterface::Normal;
+ return FilterPluginInterface::Normal;
// case CROSS_FIELD_SMOOTHING:
// return MeshFilterInterface::Smoothing;
default :
assert(0);
- return MeshFilterInterface::Generic;
+ return FilterPluginInterface::Generic;
}
}
-MeshFilterInterface::FILTER_ARITY FilterVoronoiPlugin::filterArity(const QAction* a) const
+FilterPluginInterface::FILTER_ARITY FilterVoronoiPlugin::filterArity(const QAction* a) const
{
switch(ID(a)) {
case VORONOI_SAMPLING :
diff --git a/src/meshlabplugins/filter_voronoi/filter_voronoi.h b/src/meshlabplugins/filter_voronoi/filter_voronoi.h
index 6edee9ebc..6db844051 100644
--- a/src/meshlabplugins/filter_voronoi/filter_voronoi.h
+++ b/src/meshlabplugins/filter_voronoi/filter_voronoi.h
@@ -24,13 +24,13 @@
#ifndef FILTER_VORONOI_H
#define FILTER_VORONOI_H
-#include
+#include
-class FilterVoronoiPlugin : public QObject, public MeshFilterInterface
+class FilterVoronoiPlugin : public QObject, public FilterPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_FILTER_INTERFACE_IID)
- Q_INTERFACES(MeshFilterInterface)
+ MESHLAB_PLUGIN_IID_EXPORTER(FILTER_PLUGIN_INTERFACE_IID)
+ Q_INTERFACES(FilterPluginInterface)
public:
enum {
diff --git a/src/meshlabplugins/io_3ds/meshio.h b/src/meshlabplugins/io_3ds/meshio.h
index cb63aa055..110b161c9 100644
--- a/src/meshlabplugins/io_3ds/meshio.h
+++ b/src/meshlabplugins/io_3ds/meshio.h
@@ -32,7 +32,7 @@
class ExtraMeshIOPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
diff --git a/src/meshlabplugins/io_base/baseio.h b/src/meshlabplugins/io_base/baseio.h
index b92762168..ed284a0a6 100644
--- a/src/meshlabplugins/io_base/baseio.h
+++ b/src/meshlabplugins/io_base/baseio.h
@@ -29,7 +29,7 @@
class BaseMeshIOPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
diff --git a/src/meshlabplugins/io_bre/io_bre.h b/src/meshlabplugins/io_bre/io_bre.h
index 90a90bc05..f9cb3b373 100644
--- a/src/meshlabplugins/io_bre/io_bre.h
+++ b/src/meshlabplugins/io_bre/io_bre.h
@@ -153,7 +153,7 @@ namespace io {
class BreMeshIOPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
public:
diff --git a/src/meshlabplugins/io_collada/io_collada.h b/src/meshlabplugins/io_collada/io_collada.h
index fffccf15a..82bb7aceb 100644
--- a/src/meshlabplugins/io_collada/io_collada.h
+++ b/src/meshlabplugins/io_collada/io_collada.h
@@ -50,7 +50,7 @@
class ColladaIOPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
public:
diff --git a/src/meshlabplugins/io_ctm/io_ctm.h b/src/meshlabplugins/io_ctm/io_ctm.h
index eeeb0a23d..dc0e1b013 100644
--- a/src/meshlabplugins/io_ctm/io_ctm.h
+++ b/src/meshlabplugins/io_ctm/io_ctm.h
@@ -37,7 +37,7 @@
class IOMPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
diff --git a/src/meshlabplugins/io_expe/io_expe.h b/src/meshlabplugins/io_expe/io_expe.h
index 679cb8960..17cbd9cb2 100644
--- a/src/meshlabplugins/io_expe/io_expe.h
+++ b/src/meshlabplugins/io_expe/io_expe.h
@@ -32,7 +32,7 @@
class ExpeIOPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
diff --git a/src/meshlabplugins/io_json/io_json.h b/src/meshlabplugins/io_json/io_json.h
index 80032ad1c..333286cca 100644
--- a/src/meshlabplugins/io_json/io_json.h
+++ b/src/meshlabplugins/io_json/io_json.h
@@ -29,7 +29,7 @@
class JSONIOPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
public:
diff --git a/src/meshlabplugins/io_pdb/io_pdb.h b/src/meshlabplugins/io_pdb/io_pdb.h
index 11e9fff15..d211d9867 100644
--- a/src/meshlabplugins/io_pdb/io_pdb.h
+++ b/src/meshlabplugins/io_pdb/io_pdb.h
@@ -30,7 +30,7 @@
class PDBIOPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
diff --git a/src/meshlabplugins/io_tri/io_tri.h b/src/meshlabplugins/io_tri/io_tri.h
index 5f919fc79..6b3615a05 100755
--- a/src/meshlabplugins/io_tri/io_tri.h
+++ b/src/meshlabplugins/io_tri/io_tri.h
@@ -37,7 +37,7 @@
class TriIOPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
diff --git a/src/meshlabplugins/io_txt/io_txt.h b/src/meshlabplugins/io_txt/io_txt.h
index bf0e0638b..5bcd8b725 100755
--- a/src/meshlabplugins/io_txt/io_txt.h
+++ b/src/meshlabplugins/io_txt/io_txt.h
@@ -31,7 +31,7 @@
class TxtIOPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
diff --git a/src/meshlabplugins/io_u3d/io_u3d.h b/src/meshlabplugins/io_u3d/io_u3d.h
index 17238a2c5..33b175fad 100644
--- a/src/meshlabplugins/io_u3d/io_u3d.h
+++ b/src/meshlabplugins/io_u3d/io_u3d.h
@@ -36,7 +36,7 @@
class U3DIOPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
public:
diff --git a/src/meshlabplugins/io_x3d/io_x3d.h b/src/meshlabplugins/io_x3d/io_x3d.h
index c1c7b2247..03ccb6682 100644
--- a/src/meshlabplugins/io_x3d/io_x3d.h
+++ b/src/meshlabplugins/io_x3d/io_x3d.h
@@ -40,7 +40,7 @@
class IoX3DPlugin : public QObject, public IOPluginInterface
{
Q_OBJECT
- MESHLAB_PLUGIN_IID_EXPORTER(MESH_IO_INTERFACE_IID)
+ MESHLAB_PLUGIN_IID_EXPORTER(IO_PLUGIN_INTERFACE_IID)
Q_INTERFACES(IOPluginInterface)
diff --git a/src/meshlabserver/mainserver.cpp b/src/meshlabserver/mainserver.cpp
index 0a53753b8..592523489 100644
--- a/src/meshlabserver/mainserver.cpp
+++ b/src/meshlabserver/mainserver.cpp
@@ -89,7 +89,7 @@ public:
void dumpPluginInfoWiki(FILE *fp)
{
if(!fp) return;
- foreach(MeshFilterInterface *iFilter, PM.meshFilterPlugins())
+ foreach(FilterPluginInterface *iFilter, PM.meshFilterPlugins())
foreach(QAction *filterAction, iFilter->actions())
fprintf(fp, "*%s
%s
\n", qUtf8Printable(filterAction->text()), qUtf8Printable(iFilter->filterInfo(filterAction)));
}
@@ -102,7 +102,7 @@ public:
fprintf(fp,"/*! \\mainpage MeshLab Filter Documentation\n");
//fprintf(fp,"\\AtBeginDocument{\\setcounter{tocdepth}{1}}");
- foreach(MeshFilterInterface *iFilter, PM.meshFilterPlugins())
+ foreach(FilterPluginInterface *iFilter, PM.meshFilterPlugins())
{
foreach(QAction *filterAction, iFilter->actions())
{
@@ -585,7 +585,7 @@ public:
return false;
}
- MeshFilterInterface *iFilter = qobject_cast(action->parent());
+ FilterPluginInterface *iFilter = qobject_cast(action->parent());
iFilter->setLog(&log);
int req = iFilter->getRequirements(action);
if (mm != NULL)
@@ -644,7 +644,7 @@ public:
atts[MLRenderingData::ATT_NAMES::ATT_VERTPOSITION] = true;
atts[MLRenderingData::ATT_NAMES::ATT_VERTNORMAL] = true;
- if (iFilter->filterArity(action) == MeshFilterInterface::SINGLE_MESH)
+ if (iFilter->filterArity(action) == FilterPluginInterface::SINGLE_MESH)
{
MLRenderingData::PRIMITIVE_MODALITY pm = MLPoliciesStandAloneFunctions::bestPrimitiveModalityAccordingToMesh(meshDocument.mm());
if ((pm != MLRenderingData::PR_ARITY) && (meshDocument.mm() != NULL))