Mmg
Simplicial remeshers (mesh adaptation, isovalue discretization, lagrangian movement)
Functions
main_hsiz.c File Reference
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
#include <signal.h>
#include <string.h>
#include <ctype.h>
#include <math.h>
#include <float.h>
#include "mmg/mmg2d/libmmg2d.h"
Include dependency graph for main_hsiz.c:

Go to the source code of this file.

Functions

int main (int argc, char *argv[])
 

Function Documentation

◆ main()

int main ( int  argc,
char *  argv[] 
)

Example of use of the mmg2dls function of the mmg2d library (basic use of level-set discretization option): here the user only provide the level-set

Author
Charles Dapogny (LJLL, UPMC)
Pascal Frey (LJLL, UPMC)
Algiane Froehly (Inria / IMB, Université de Bordeaux)
Version
5

1) Initialisation of mesh and sol structures

-------------— Enable the level set discretization -----------------—

2) Build mesh in MMG5 format

Two solutions: just use the MMG2D_loadMesh function that will read a .mesh(b) file formatted or manually set your mesh using the MMG2D_Set* functions

with MMG2D_loadMesh function

3) Build the level-set in MMG5 format

Two solutions: just use the MMG2D_loadSol function that will read a .sol(b) file formatted or manually set your level-set using the MMG2D_Set* functions

load the level-set With the MMG2D_loadSol function

4) (not mandatory): check if the number of given entities match with mesh size

5) (not mandatory): set your global parameters using the MMG2D_Set_iparameter and MMG2D_Set_dparameter function (resp. for integer parameters and double param)

----------------— level set discretization ------------------------—

isovalue discretization: as we don't want to impose an input metric we pass NULL instead of the metric structure as function argument

Definition at line 50 of file main_hsiz.c.

Here is the call graph for this function: