11 #ifndef MESH_PROCESS_CREATION_HPP 12 #define MESH_PROCESS_CREATION_HPP 16 #include <Polygonizer.hpp> 33 , progress(
"Marching Cubes Surface", 0)
39 if(!checkState().store(STORE_NON_EMPTY).mesh())
42 _stack = currentStack();
43 _store = _stack->currentStore();
44 Mesh* mesh = currentMesh();
46 bool result = (*this)(mesh, _store, parms[0].toFloat(), parms[1].toInt());
49 if(result and not mesh->isSurfaceVisible() and not mesh->isMeshVisible())
54 bool operator()(
Mesh* mesh,
const Store* store,
float cubeSize,
int threshold);
60 return "Marching Cubes Surface";
64 return "Extract surface mesh with marching cubes. A threshold to 0 will interpret the image as binary.";
71 return QStringList() <<
"Size for the marching cubes." 72 <<
"Minimal signal used for surface extraction.";
80 return QIcon(
":/images/MarchCubes.png");
103 , progress(
"Marching Cubes 3D", 0)
109 if(!checkState().store(STORE_LABEL).mesh())
112 _stack = currentStack();
113 _store = _stack->currentStore();
114 Mesh* mesh = currentMesh();
116 bool result = (*this)(mesh, _store, parms[0].toFloat(), parms[1].toInt(), parms[2].toInt(), parms[3].toInt());
119 if(result and not mesh->isSurfaceVisible() and not currentMesh()->isMeshVisible())
120 currentMesh()->showSurface();
124 bool operator()(
Mesh* mesh,
const Store* store,
float cubeSize,
int minVoxels,
int smooth,
int singleLabel);
130 return "Marching Cubes 3D";
133 return "Extract 3D meshes with marching cubes";
143 return QStringList() <<
"Size for the marching cubes." 144 <<
"Minimal number of voxels for extracting surface." 146 <<
"Extract surface only for this label.";
156 return QIcon(
":/images/MarchCubes3D.png");
184 if(!checkState().mesh())
186 return (*
this)(currentMesh());
189 bool operator()(
Mesh* mesh);
195 return "Mesh Cutting Surface";
198 return "Make mesh from cutting surface";
207 return QIcon(
":/images/MakePlane.png");
bool operator()(const QStringList &parms)
Implementation of the process with generic arguments.
Definition: MeshProcessCreation.hpp:37
QIcon icon() const
Icon to use to represent the process in the GUI.
Definition: MeshProcessCreation.hpp:206
Definition: Polygonizer.hpp:36
QStringList parmNames() const
List of named parameters.
Definition: MeshProcessCreation.hpp:200
arg(const QString &a, int fieldWidth=0, const QChar &fillChar=QLatin1Char( ' ')
QStringList parmNames() const
List of named parameters.
Definition: MeshProcessCreation.hpp:66
QString name() const
Returns the name of the process.
Definition: MeshProcessCreation.hpp:59
QStringList parmDescs() const
List of parameters descriptions.
Definition: MeshProcessCreation.hpp:203
QString folder() const
Folder in which to place the process.
Definition: MeshProcessCreation.hpp:126
QStringList parmDescs() const
List of parameters descriptions.
Definition: MeshProcessCreation.hpp:141
The Store class holds the actual 3D data and properties specific to it.
Definition: Store.hpp:35
This class holds the actual mesh as a VV Graph and all sort of properties for it, including visualiza...
Definition: Mesh.hpp:177
Definition: MeshProcessCreation.hpp:98
QStringList parmDefaults() const
List of default parms.
Definition: MeshProcessCreation.hpp:148
Create a surface matching the current cutting surface, whether it's a plane or a Bezier surface...
Definition: MeshProcessCreation.hpp:174
This namespace contains all the API of MorphoGraphX.
Definition: Assert.hpp:26
QStringList parmNames() const
List of named parameters.
Definition: MeshProcessCreation.hpp:135
Definition: Progress.hpp:99
bool operator()(const QStringList &)
Implementation of the process with generic arguments.
Definition: MeshProcessCreation.hpp:182
bool operator()(const QStringList &parms)
Implementation of the process with generic arguments.
Definition: MeshProcessCreation.hpp:107
Find the surface of a volume defined by an iso-surface on the image intensity using a variation on th...
Definition: MeshProcessCreation.hpp:28
File containing the definition of a Process.
The Stack class represent the dimensions of the 3D data, and the frames transformations.
Definition: Stack.hpp:35
QIcon icon() const
Icon to use to represent the process in the GUI.
Definition: MeshProcessCreation.hpp:155
This is the main process class, the one all process inherit from.
Definition: Process.hpp:258
QString description() const
Returns a description of the process for the GUI.
Definition: MeshProcessCreation.hpp:197
This namespace contains all the classes needed to define processes.
QString description() const
Returns a description of the process for the GUI.
Definition: MeshProcessCreation.hpp:132
QString name() const
Returns the name of the process.
Definition: MeshProcessCreation.hpp:129
QString folder() const
Folder in which to place the process.
Definition: MeshProcessCreation.hpp:191
QString description() const
Returns a description of the process for the GUI.
Definition: MeshProcessCreation.hpp:62
QString folder() const
Folder in which to place the process.
Definition: MeshProcessCreation.hpp:56
QStringList parmDefaults() const
List of default parms.
Definition: MeshProcessCreation.hpp:74
QString name() const
Returns the name of the process.
Definition: MeshProcessCreation.hpp:194
Mesh processes have mutable access to meshes and non-mutable access to stacks.
Definition: Process.hpp:865
QIcon icon() const
Icon to use to represent the process in the GUI.
Definition: MeshProcessCreation.hpp:79
QStringList parmDescs() const
List of parameters descriptions.
Definition: MeshProcessCreation.hpp:69