Mmg
Simplicial remeshers (mesh adaptation, isovalue discretization, lagrangian movement)
|
C API functions definitions for MMG library. More...
#include "mmgcommon_private.h"
Go to the source code of this file.
C API functions definitions for MMG library.
C API for MMG library.
Definition in file API_functions.c.
int MMG5_Compute_constantSize | ( | MMG5_pMesh | mesh, |
MMG5_pSol | met, | ||
double * | hsize | ||
) |
mesh | pointer toward the mesh structure. |
met | pointer toward the metric. |
hsiz | computed constant size to impose. |
Compute the constant size to impose according to hmin and hmax and store it in hsiz. Fill hmin and hamx if they are not setted by the user.
Definition at line 572 of file API_functions.c.
int MMG5_Free_allSols | ( | MMG5_pMesh | mesh, |
MMG5_pSol * | sol | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward an array of solution structure (that stores solution fields). |
Deallocation of an array of solution fields
Definition at line 440 of file API_functions.c.
void MMG5_Free_structures | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
Structures unallocation before return (common structures between all codes).
Definition at line 462 of file API_functions.c.
char * MMG5_Get_basename | ( | char * | path | ) |
path | string containing a filename and its path |
Extract basename from a path (allocate a string to store it).
Definition at line 632 of file API_functions.c.
const char * MMG5_Get_entitiesName | ( | enum MMG5_entities | ent | ) |
ent | MMG5_entities enum |
Print the name associated to the ent value in the MMG5_entities enum.
Definition at line 642 of file API_functions.c.
char * MMG5_Get_filenameExt | ( | char * | filename | ) |
filename | string containing a filename |
Get the extension of the filename string. Do not consider '.o' as an extension.
Definition at line 856 of file API_functions.c.
int MMG5_Get_format | ( | char * | ptr, |
int | fmt | ||
) |
ptr | pointer toward the file extension (dot included) |
fmt | default file format. |
Get the wanted file format from the mesh extension. If fmt is provided, it is used as default file format (ptr==NULL), otherwise, the default file format is the medit one.
Definition at line 760 of file API_functions.c.
const char * MMG5_Get_formatName | ( | enum MMG5_Format | fmt | ) |
fmt | file format. |
Print the name of the file format associated to fmt.
Definition at line 808 of file API_functions.c.
char * MMG5_Get_path | ( | char * | path | ) |
path | string containing a filename and its path |
Remove filename from a path and return the path in a newly allocated string.
Definition at line 883 of file API_functions.c.
const char * MMG5_Get_tagName | ( | int | tag | ) |
tag | input entity tag |
Print the name associated to the typ value in the MMG5_type enum.
Definition at line 686 of file API_functions.c.
const char * MMG5_Get_typeName | ( | enum MMG5_type | typ | ) |
typ | MMG5_type enum |
Print the name associated to the typ value in the MMG5_type enum.
Definition at line 665 of file API_functions.c.
void MMG5_Init_fileNames | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
Initialize file names to their default values.
Definition at line 128 of file API_functions.c.
void MMG5_Init_parameters | ( | MMG5_pMesh | mesh | ) |
mesh | pointer toward the mesh structure. |
Initialization of the input parameters.
MMG3D_IPARAM_lag is used by mmg3d only but need to be negative in the scaleMesh function
Definition at line 51 of file API_functions.c.
void MMG5_mmgFree_names | ( | MMG5_pMesh | mesh, |
MMG5_pSol | met | ||
) |
mesh | pointer toward the mesh structure. |
met | pointer toward the sol structure. |
File name deallocations before return.
Definition at line 511 of file API_functions.c.
char * MMG5_Remove_ext | ( | char * | path, |
char * | ext | ||
) |
path | path from which we want to remove the extension. |
Allocate a new string and copy path without extension in it.
Definition at line 918 of file API_functions.c.
void MMG5_Set_constantSize | ( | MMG5_pMesh | mesh, |
MMG5_pSol | met, | ||
double | hsiz | ||
) |
mesh | pointer toward the mesh structure. |
met | pointer toward the sol structure. |
hsiz | wanted edge size |
fill the metric field with the size hsiz
\Remark not for extern users.
Definition at line 395 of file API_functions.c.
|
inline |
mesh | pointer toward the mesh structure. |
sethmin | 1 if hmin is already setted (>0.) |
sethmax | 1 if hmax is already setted (>0.) |
Set default values for hmin and hmax from the bounding box.
\Remark not for extern users.
Definition at line 535 of file API_functions.c.
int MMG5_Set_inputMeshName | ( | MMG5_pMesh | mesh, |
const char * | meshin | ||
) |
mesh | pointer toward the mesh structure. |
meshin | input mesh name. |
Set the name of input mesh.
Definition at line 149 of file API_functions.c.
int MMG5_Set_inputSolName | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | solin | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
solin | name of the input solution file. |
Set the name of input solution file.
Definition at line 185 of file API_functions.c.
int MMG5_Set_outputMeshName | ( | MMG5_pMesh | mesh, |
const char * | meshout | ||
) |
mesh | pointer toward the mesh structure. |
meshout | name of the output mesh file. |
Set the name of output mesh file.
Definition at line 233 of file API_functions.c.
int MMG5_Set_outputSolName | ( | MMG5_pMesh | mesh, |
MMG5_pSol | sol, | ||
const char * | solout | ||
) |
mesh | pointer toward the mesh structure. |
sol | pointer toward the sol structure. |
solout | name of the output solution file. |
Set the name of output solution file.
Definition at line 348 of file API_functions.c.