Hi Algiane,
I am using MMG3D_mmg3dls(mmgMesh, mmgLs, NULL) to obtain my level set discretization. Prior to this I am using MMG3D_mmg3dlib(mmgMesh, mmgMet) to remesh the initial mesh based on parameters derived from my level set functions that ensure the mesh is of an adequate size, i.e. that it can accurately capture the level set but is at the same time not finer than necessary to avoid unnecessary slowdown. If use an intermediate mmgMeshB created by either copying the data or loading it from a temporary .mesh file it all works. However, I would prefer to be able to reuse the mmgMesh I get from MMG3D_mmg3dlib() right away when I call MMG3D_mmg3dls(). Just giving MMG3D_mmg3dls() the mmgMesh I get from MMG3D_mmg3dlib() results in the following error:
## Problem in setting boundary. Exit program.
BAD ENDING OF MMG3DLS: UNABLE TO SAVE MESH
My guess is that this is because I need to reset some stuff in mmgMesh. I considered trying to reset stuff manually myself to see if I can get it to work but figured it’s probably a very bad idea since as mmg continues developing such a dirty fix will surely break at some point (and there is probably a better way). If this is indeed the problem what the best way for me to ‘reset’ the necessary stuff in mmgMesh? and if its not this, perhaps you can point me to what the problem is.
Another problem I expect I will get, since I saw something mentioned about it in one of the examples, and am not sure how to deal with, is that I have not set MMG3D_Set_iparameter(mmgMesh,mmgLs,MMG3D_IPARAM_iso, 1) != 1 ) prior to loading the mesh as it is first used by MMG3D_mmg3dlib(). Or maybe this is actually whats causing my problem?
Hopefully you can help me out.
Regards,
K