MorphoGraphX
|
Classes and functions needed to create your own processes or call other processes. More...
Classes | |
class | mgx::process::UserCancelException |
Exception launched when a user clicks the Cancel button. More... | |
class | mgx::process::Process |
This is the main process class, the one all process inherit from. More... | |
class | mgx::process::StackProcess |
Stack processes have non-mutable access to meshes and mutable access to stacks. More... | |
class | mgx::process::MeshProcess |
Mesh processes have mutable access to meshes and non-mutable access to stacks. More... | |
class | mgx::process::GlobalProcess |
Global processes have full mutable access to all properties of the process. More... | |
struct | mgx::process::BaseProcessDefinition |
Definition of a process, without the process factory. More... | |
class | mgx::process::ProcessDefinition< P > |
Definition of a process, including the process factory. More... | |
Macros | |
#define | REGISTER_STACK_PROCESS(ClassName) |
Register ClassName has a stack process. More... | |
#define | REGISTER_MESH_PROCESS(ClassName) |
Register ClassName has a mesh process. More... | |
#define | REGISTER_GLOBAL_PROCESS(ClassName) |
Register ClassName has a global process. More... | |
Typedefs | |
typedef QHash< int, QStringList > | mgx::process::ParmChoiceMap |
Type of the dictionary giving the list of possible strings for each argument. More... | |
Functions | |
mgxBase_EXPORT bool | mgx::process::subdivideBisect (vvgraph &S, const vertex &v1, const vertex &v2, const vertex &v3, bool selected, std::vector< vertex > *vs=0) |
Subdivide triangle by bi-sections. More... | |
mgxBase_EXPORT void | mgx::process::markMargin (vvgraph &M, vvgraph &S, bool remborders) |
Mark the cells and tissue margin vertices. More... | |
mgx_EXPORT BaseProcessDefinition * | mgx::process::getBaseProcessDefinition (const QString &processType, const QString &processName) |
Retrieves the process definition from the type and name of the process. More... | |
mgx_EXPORT bool | mgx::process::getLastParms (const Process &proc, QStringList &parms) |
Get the parameters for a given process. | |
mgx_EXPORT bool | mgx::process::getDefaultParms (const Process &proc, QStringList &parms) |
Get the default parameters for a given process (i.e. the ones defined by the process) | |
mgx_EXPORT bool | mgx::process::saveDefaultParms (const Process &proc, const QStringList &parms) |
Save the default parameters in memory. | |
mgx_EXPORT bool | mgx::process::checkProcessParms (const Process &proc, const QStringList &parms, size_t *nbParms=0) |
Check if the parameters have enough defaults. | |
mgx_EXPORT bool | mgx::process::getLastParms (const QString &processType, const QString &processName, QStringList &parms) |
Get the parameters for a given process. | |
mgx_EXPORT bool | mgx::process::getDefaultParms (const QString &processType, const QString &processName, QStringList &parms) |
Get the default parameters for a given process (i.e. the ones defined by the process) | |
mgx_EXPORT bool | mgx::process::saveDefaultParms (const QString &processType, const QString &processName, const QStringList &parms) |
Save the default parameters in memory. | |
mgx_EXPORT bool | mgx::process::checkProcessParms (const QString &processType, const QString &processName, const QStringList &parms, size_t *nbParms=0) |
Check if the parameters have enough defaults. | |
mgx_EXPORT QStringList | mgx::process::listProcesses (const QString &processType) |
Returns the list of names of the processes of a given type. | |
mgx_EXPORT bool | mgx::process::validProcessType (const QString &processType) |
Check if processType is a valid type (i.e. More... | |
mgx_EXPORT bool | mgx::process::validProcessName (const QString &processType, const QString &processName) |
Check if the processName exist in the list of processType . | |
mgx_EXPORT bool | mgx::process::stringToBool (const QString &string) |
Helper function converting a string into a boolean. | |
mgx_EXPORT bool | mgx::process::stringToWorkStore (const QString &string) |
Returns true if string correspond to the work store, false otherwise. | |
mgx_EXPORT bool | mgx::process::stringToMainStore (const QString &string) |
Returns true if string correspond to the main store, false otherwise. | |
QString | mgx::process::boolToString (bool b) |
Helper function converting a boolean into a string. | |
mgx_EXPORT bool | mgx::process::meshFromTriangles (vvgraph &S, std::vector< vertex > &vertices, std::vector< Point3i > &triangles) |
This function creates a graph from a triangle soup. More... | |
Classes and functions needed to create your own processes or call other processes.
#define REGISTER_GLOBAL_PROCESS | ( | ClassName | ) |
Register ClassName
has a global process.
It must inherit GlobalProcess and have a constructor accepting a single GlobalProcess.
#define REGISTER_MESH_PROCESS | ( | ClassName | ) |
Register ClassName
has a mesh process.
It must inherit MeshProcess and have a constructor accepting a single MeshProcess.
#define REGISTER_STACK_PROCESS | ( | ClassName | ) |
Register ClassName
has a stack process.
It must inherit StackProcess and have a constructor accepting a single StackProcess.
typedef QHash<int, QStringList> mgx::process::ParmChoiceMap |
Type of the dictionary giving the list of possible strings for each argument.
If the choice is free, the position should just not be present in the dictionnary.
mgx_EXPORT BaseProcessDefinition * mgx::process::getBaseProcessDefinition | ( | const QString & | processType, |
const QString & | processName | ||
) |
Retrieves the process definition from the type and name of the process.
Get the definition of a process.
mgxBase_EXPORT void mgx::process::markMargin | ( | vvgraph & | M, |
vvgraph & | S, | ||
bool | remborders | ||
) |
Mark the cells and tissue margin vertices.
M | subset of the graph to consider |
S | full tissue |
remborders | If true, all vertices with -1 as label and not at the border between cells will be marked as 0. |
mgx_EXPORT bool mgx::process::meshFromTriangles | ( | vvgraph & | S, |
std::vector< vertex > & | vertices, | ||
std::vector< Point3i > & | triangles | ||
) |
This function creates a graph from a triangle soup.
S | Graph that will be updated. |
vertices | List of vertices to insert in S |
triangles | List of triplet of indices in vertices defining triangles |
mgxBase_EXPORT bool mgx::process::subdivideBisect | ( | vvgraph & | S, |
const vertex & | v1, | ||
const vertex & | v2, | ||
const vertex & | v3, | ||
bool | selected, | ||
std::vector< vertex > * | vs = 0 |
||
) |
Subdivide triangle by bi-sections.
S | Graph to subdivide |
v1 | First vertex of the triangle to divide |
v2 | Second vertex of the triangle to divide |
v3 | Third vertex of the triangle to divide |
selected | If true, new vertices will be selected |
vs | If non-NULL, vertices inserted are appended |
mgx_EXPORT bool mgx::process::validProcessType | ( | const QString & | processType | ) |
Check if processType
is a valid type (i.e.
it exists)