59 MMG5_int base,*adja,nump,k,k1;
65 assert( 0<=ip && ip<4 &&
"unexpected local index for vertex");
70 list[0] = 4*start + ip;
75 while ( cur < ilist ) {
86 if ( pt1->
flag == base )
continue;
89 if ( pt1->
v[j] == nump )
break;
117 int8_t *mmgWarn,int8_t *ia) {
121 for ((*ia)=0; (*ia)<6; (*ia)++) {
124 if ( (pt->
v[ipa] == na && pt->
v[ipb] == nb) ||
125 (pt->
v[ipa] == nb && pt->
v[ipb] == na))
break;
129 if ( (*ia)<6 )
return 1;
132 fprintf(stderr,
"\n ## Error: %s: wrong edge's shell: "
133 " edge %" MMG5_PRId
" %" MMG5_PRId
" not found in tetra %" MMG5_PRId
".\n",__func__,
136 fprintf(stderr,
" Exit program.\n");
141 fprintf(stderr,
"\n ## Warning: %s: at least one wrong edge's"
142 " shell.\n",__func__);
158 l0 = (ppt->
c[0] - p0->
c[0])*(ppt->
c[0] - p0->
c[0]) \
159 + (ppt->
c[1] - p0->
c[1])*(ppt->
c[1] - p0->
c[1]) + (ppt->
c[2] - p0->
c[2])*(ppt->
c[2] - p0->
c[2]);
160 l1 = (ppt->
c[0] - p1->
c[0])*(ppt->
c[0] - p1->
c[0]) \
161 + (ppt->
c[1] - p1->
c[1])*(ppt->
c[1] - p1->
c[1]) + (ppt->
c[2] - p1->
c[2])*(ppt->
c[2] - p1->
c[2]);
166 for ( i=0; i<3; ++i ) {
167 t[i] = p1->
c[i] - p0->
c[i];
170 else if ( l0 < l1 ) {
172 for ( i=0; i<3; ++i ) {
173 t[i] = dd*(p1->
c[i] - ppt->
c[i]) + ppt->
c[i] - p0->
c[i];
178 for ( i=0; i<3; ++i ) {
179 t[i] = dd*(p0->
c[i] - ppt->
c[i]) + ppt->
c[i] - p1->
c[i];
200 double n[3],
double t[3]) {
204 MMG5_int base,nump,k,*adja,piv,nvstart,aux,na,nb,adj,fstart,ip0,ip1;
206 int8_t iopp,ipiv,indb,inda,i,isface;
207 int8_t indedg[4][4] = { {-1,0,1,2}, {0,-1,3,4}, {1,3,-1,5}, {2,4,5,-1} };
213 memset(n,0x00,3*
sizeof(
double));
214 memset(t,0x00,3*
sizeof(
double));
235 for ( inda=0; inda<4; inda++ ){
236 if ( pt->
v[inda]==na )
break;
238 for ( indb=0; indb<4; indb++ ){
239 if ( pt->
v[indb]==nb )
break;
241 assert( (inda < 4) && (indb < 4));
249 else if ( tag &
MG_NOM ) {
269 if ( pt->
flag != base ) {
271 if ( pt->
v[i] == nump )
break;
292 isface = (adja[iopp] == 0);
294 while ( adj && (adj != nvstart) && !isface );
296 while ( 4*k+iopp != fstart );
298 if ( (nr > 0 && nnm > 0) || nnm != 2 ) {
303 dd = n[0]*n[0] + n[1]*n[1] + n[2]*n[2];
310 assert( ip0 && ip1 );
311 if ( ip0 == ip1 )
return 0;
315 dd = t[0]*n[0] + t[1]*n[1] + t[2]*n[2];
320 dd = t[0]*t[0] + t[1]*t[1] + t[2]*t[2];
349 MMG5_int base,k,kk,ip0,ip1,nump,na,nb,list[
MMG3D_LMAX+2],*adja;
360 list[0] = 4*start+ip;
364 while ( cur < ilist ) {
372 for (j=0; j<3; j++) {
379 if ( ip0 == 0 ) ip0 = nb;
380 else if ( ip1 == 0 ) {
381 if ( ip0 != nb ) ip1 = nb;
384 if ( ip0 != nb && ip1 != nb )
return 0;
389 if ( ip0 == 0 ) ip0 = na;
390 else if ( ip1 == 0 ) {
391 if ( ip0 != na ) ip1 = na;
394 if ( ip0 != na && ip1 != na )
return 0;
404 for (j=0; j<3; j++) {
407 assert ( kk &&
"point is not an internal nm-point");
415 if ( pt1->
flag == base )
continue;
417 for (ii=0; ii<4; ii++)
418 if ( pt1->
v[ii] == nump )
break;
421 list[ilist] = 4*kk+ii;
433 dd = t[0]*t[0] + t[1]*t[1] + t[2]*t[2];
462 MMG5_int *adja,nump,k,k1;
464 MMG5_int list[
MMG3D_LMAX+2],base,ia,ib,a,b,key,jj;
469 for ( k=0; k<=hash->
max; ++k ) {
474 for ( k=0; k<=hash->
siz; ++k ) {
477 for (k=hash->
siz; k<hash->max; k++) {
487 list[0] = 4*start + ip;
490 *ng = *nr = *nm = ns = 0;
494 while ( cur < ilist ) {
502 for (l=0; l<3; ++l) {
513 ph = &hash->
item[key];
515 if ( ph->
a == ia && ph->
b == ib )
518 while ( ph->
nxt && ph->
nxt < hash->
max ) {
520 if ( ph->
a == ia && ph->
b == ib )
continue;
525 if ( hash->
nxt >= hash->
max-1 ) {
527 fprintf(stderr,
"\n ## Warning: %s: memory alloc problem (edge):"
528 " %" MMG5_PRId
"\n",__func__,hash->
max);
530 "MMG5_edge",
return -1);
534 for (jj=ph->
nxt; jj<hash->max; jj++) hash->
item[jj].
nxt = jj+1;
565 for (l=0; l<3; l++) {
571 if ( pt1->
flag == base )
continue;
574 if ( pt1->
v[j] == nump )
break;
578 list[ilist] = 4*k1+j;
611 int64_t *listv,
int *ilistv,MMG5_int *lists,
int*ilists,
int isnm)
615 MMG5_int k,*adja,nump,k1,fstart,piv,na,nb,adj,nvstart,aux,cur,base;
616 int8_t iopp,ipiv,i,j,l,isface;
617 static int8_t mmgErr0=0, mmgErr1=0, mmgErr2=0;
619 if ( isnm ) assert(!
mesh->
adja[4*(start-1)+iface+1]);
638 lists[(*ilists)] = 4*k+iopp;
641 assert (
mesh->
tetra[k].
xt &&
"tetra of surfacic ball has a xtetra (bdy face) ");
645 fprintf(stderr,
"\n ## Warning: %s: problem in surface remesh process."
646 " Surface ball of at least 1 point (%" MMG5_PRId
") contains too"
648 " ## Try to modify the hausdorff number "
649 " or/and the maximum edge size.\n",__func__,
668 if ( pt->
flag != base ) {
670 if ( pt->
v[i] == nump )
break;
672 listv[(*ilistv)] = 4*k+i;
684 adj = adja[ iopp ] / 4;
690 adj = adja[ iopp ] / 4;
694 isface = (adja[iopp] == 0);
704 while ( adj && (adj != nvstart) && !isface );
706 while ( 4*k+iopp != fstart );
710 while ( cur < (*ilistv) ) {
715 for (l=0; l<3; l++) {
721 if ( pt1->
flag == base )
continue;
725 if ( pt1->
v[j] == nump )
break;
731 fprintf(stderr,
"\n ## Warning: %s: problem in remesh process."
732 " Volumic ball of point %" MMG5_PRId
" contains too many elts.\n",
734 fprintf(stderr,
"\n ## Try to modify the hausdorff number,"
735 " or/and the maximum mesh.\n");
740 listv[(*ilistv)] = 4*k1+j;
781 int64_t *listv,
int *ilistv, MMG5_int *lists,
int *ilists,
782 MMG5_int *refmin, MMG5_int *refplus,
int isnm)
786 MMG5_int k, k1, nump, *adja, piv, na, nb, adj, cur, nvstart, fstart, aux, base;
787 int8_t iopp, ipiv, i, j, l, isface;
788 static int8_t mmgErr0=0, mmgErr1=0, mmgErr2=0;
790 if ( isnm ) assert(!
mesh->
adja[4*(start-1)+iface+1]);
811 lists[(*ilists)] = 4*k+iopp;
815 fprintf(stderr,
"\n ## Warning: %s: problem in surface remesh process."
816 " Surface ball of at least 1 point (%" MMG5_PRId
") contains too"
818 " ## Try to modify the hausdorff number "
819 " or/and the maximum edge size.\n",__func__,
837 if ( pt->
flag != base ) {
839 if ( pt->
v[i] == nump )
break;
841 listv[(*ilistv)] = 4*k+i;
848 if ( *refplus == -1 ) {
849 if ( pt->
ref != *refmin ) *refplus = pt->
ref;
851 else if ( pt->
ref != *refmin && pt->
ref != *refplus )
return -2;
863 adj = adja[ iopp ] / 4;
869 adj = adja[ iopp ] / 4;
873 isface = (adja[iopp] == 0);
883 while ( adj && (adj != nvstart) && !isface );
885 while ( 4*k+iopp != fstart );
889 while ( cur < (*ilistv) ) {
894 for (l=0; l<3; l++) {
900 if ( pt1->
flag == base )
continue;
904 if ( pt1->
v[j] == nump )
break;
910 fprintf(stderr,
"\n ## Warning: %s: problem in remesh process."
911 " Volumic ball of point %" MMG5_PRId
" contains too many elts.\n",
913 fprintf(stderr,
"\n ## Try to modify the hausdorff number,"
914 " or/and the maximum mesh.\n");
919 listv[(*ilistv)] = 4*k1+j;
926 if ( *refplus == -1 ) {
927 if ( pt1->
ref != *refmin ) *refplus = pt1->
ref;
929 else if ( pt1->
ref != *refmin && pt1->
ref != *refplus )
return -2;
961 int *il2,MMG5_int *l2,MMG5_int *ip0,MMG5_int *ip1)
966 MMG5_int k,*adja,*list1,*list2,aux;
967 MMG5_int na, nb, piv,lists[
MMG3D_LMAX+2], base;
968 MMG5_int idp, fstart, nvstart, adj;
969 int ilists, iopp, ipiv,*ilist1,*ilist2;
970 int ifac,idx,idx2,idx_tmp,i1,isface;
971 double *n1,*n2,nt[3],ps1,ps2;
973 static int8_t mmgErr0=0,mmgErr1=0;
976 if ( !
MG_EOK(pt) )
return 0;
1009 ps1 = n1[0]*nt[0] + n1[1]*nt[1] + n1[2]*nt[2];
1010 ps2 = n2[0]*nt[0] + n2[1]*nt[1] + n2[2]*nt[2];
1012 if ( fabs(ps1) < fabs(ps2) ) {
1031 lists[ilists] = 4*k+iopp;
1035 fprintf(stderr,
"\n ## Warning: %s: problem in remesh process."
1036 " Volumic ball of point %" MMG5_PRId
" contains too many elts.\n",
1038 fprintf(stderr,
"\n ## Try to modify the hausdorff number,"
1039 " or/and the maximum mesh.\n");
1065 adj = adja[ iopp ] / 4;
1071 adj = adja[ iopp ] / 4;
1080 while ( adj && (adj != nvstart) && !isface );
1085 while ( 4*k+iopp != fstart );
1088 for (idx=0; idx!=ilists; ++idx) {
1090 ifac = lists[idx]%4;
1095 for ( i=0; i<3; ++i ) {
1096 if ( pt->
v[
MMG5_idir[ifac][i]] == idp )
break;
1103 assert(idx < ilists);
1108 idx = (idx+1)%ilists;
1109 for (idx2=idx; idx2!=ilists+idx; ++idx2) {
1110 idx_tmp = idx2%ilists;
1111 k = lists[idx_tmp]/4;
1112 ifac = lists[idx_tmp]%4;
1118 list2[(*ilist2)] = 4*k+ifac;
1121 for ( i=0; i<3; ++i ) {
1122 if ( pt->
v[
MMG5_idir[ifac][i]] == idp )
break;
1129 assert(idx2 != ilists+idx);
1134 idx = (idx2+1)%ilists;
1135 for (idx2=idx; idx2 != idx+ilists; ++idx2) {
1136 idx_tmp = idx2%ilists;
1137 k = lists[idx_tmp]/4;
1138 ifac = lists[idx_tmp]%4;
1144 list1[(*ilist1)] = 4*k+ifac;
1147 for ( i=0; i<3; ++i ) {
1148 if ( pt->
v[
MMG5_idir[ifac][i]] == idp )
break;
1155 assert(idx2 != ilists+idx);
1179 uint16_t tag,
int edg, MMG5_int piv,MMG5_int adj) {
1186 while ( adj && (adj != start) ) {
1197 taginit = pxt->
tag[i];
1203 pxt->
tag[i] &= ~MG_NOSURF;
1237 MMG5_int na,nb,*adja,adj,piv;
1240 assert( start >= 1 );
1253 taginit = pxt->
tag[ia];
1254 pxt->
tag[ia] |= tag;
1259 pxt->
tag[ia] &= ~MG_NOSURF;
1267 if ( adj == start )
return 1;
1268 else if ( adj < 0 )
return 0;
1279 if ( adj < 0 )
return 0;
1301 uint16_t tag,MMG5_int piv,MMG5_int adj) {
1307 while ( adj && (adj != start) ) {
1319 pxt->
tag[i] &= ~tag;
1350 MMG5_int na,nb,*adja,adj,piv;
1353 assert( start >= 1 );
1368 pxt->
tag[ia] &= ~tag;
1375 if ( adj == start )
return 1;
1376 else if ( adj < 0 )
return 0;
1387 if ( adj < 0 )
return 0;
1408 MMG5_int *adja,piv,na,nb,adj;
1411 static int8_t mmgErr0=0, mmgErr1=0;
1413 assert ( start >= 1 );
1420 list[ilist] = 6*(int64_t)start+ia;
1428 while ( adj && (adj != start) ) {
1435 list[ilist] = 6*(int64_t)adj +i;
1440 fprintf(stderr,
"\n ## Warning: %s: problem in remesh process."
1441 " Coquil of edge %" MMG5_PRId
"-%" MMG5_PRId
" contains too many elts.\n",
1443 fprintf(stderr,
"\n ## Try to modify the hausdorff number,"
1444 " or/and the maximum mesh.\n");
1453 if ( pt->
v[ travel_fac ] == piv ) {
1454 adj = adja[ travel_fac ] / 4;
1459 assert(pt->
v[ travel_fac ] == piv );
1460 adj = adja[ travel_fac ] /4;
1475 if ( adj == start )
return 2*ilist;
1478 adj = list[ilist-1] / 6;
1479 i = list[ilist-1] % 6;
1484 list[ilist] = 6*(int64_t)adj + i;
1489 fprintf(stderr,
"\n ## Warning: %s: problem in remesh process."
1490 " Coquil of edge %" MMG5_PRId
"-%" MMG5_PRId
" contains too many elts.\n",
1492 fprintf(stderr,
"\n ## Try to modify the hausdorff number,"
1493 " or/and the maximum mesh.\n");
1517 list[ilist] = 6*(int64_t)adj +i;
1522 fprintf(stderr,
"\n ## Warning: %s: problem in remesh process."
1523 " Coquil of edge %" MMG5_PRId
"-%" MMG5_PRId
" contains too many elts.\n",
1525 fprintf(stderr,
"\n ## Try to modify the hausdorff number,"
1526 " or/and the maximum mesh.\n");
1560 MMG5_int na,nb,adj,piv,*adja;
1576 adj = adja[iadj] / 4;
1579 while( adj && ( adj != start ) ) {
1589 adj = adja[ iadj ] / 4;
1594 adj = adja[ iadj ] /4;
1618 MMG5_int kel1, kel2;
1619 static int8_t mmgErr0;
1621 if ( mmgErr0 )
return;
1625 fprintf(stderr,
"\n ## Error: %s: at least 1 problem in surface"
1626 " remesh process",__func__);
1627 fprintf(stderr,
" (potential creation of a lonely boundary face):\n");
1634 assert ( pt &&
MG_EOK(pt) );
1635 fprintf(stderr,
" look at elt %" MMG5_PRId
":",kel1);
1636 fprintf(stderr,
" %" MMG5_PRId
" %" MMG5_PRId
" %" MMG5_PRId
" %" MMG5_PRId
".\n",
MMG3D_indPt(
mesh,pt->
v[0]),
1639 fprintf(stderr,
" adjacent tetras %" MMG5_PRId
" %" MMG5_PRId
" %" MMG5_PRId
" %" MMG5_PRId
"\n",
1644 fprintf(stderr,
" vertex required? %d %d %d %d\n",
1649 }
else if ( kel2 != 0 ) {
1650 fprintf(stderr,
" look at elt %" MMG5_PRId
":",kel2);
1652 assert ( pt &&
MG_EOK(pt) );
1654 fprintf(stderr,
" %" MMG5_PRId
" %" MMG5_PRId
" %" MMG5_PRId
" %" MMG5_PRId
".\n\n",
MMG3D_indPt(
mesh,pt->
v[0]),
1658 fprintf(stderr,
"\n ## Try to modify the hausdorff number,");
1659 fprintf(stderr,
" the maximum mesh size or/and the value of angle detection.\n");
1660 fprintf(stderr,
" You can also try to run with -noswap option but probably");
1661 fprintf(stderr,
" the final mesh will have poor quality.\n\n");
1690 int8_t ia,int64_t *list,
int *ilist,MMG5_int *it1,MMG5_int *it2,
1691 MMG5_int *piv,MMG5_int *adj,int8_t *hasadja,
int *nbdy,
int silent) {
1694 MMG5_int pradj,*adja;
1695 int pri,
ier,ifar_idx;
1697 static int8_t mmgErr0 = 0;
1711 ifar_idx = (
MMG5_ifar[ia][0]==iface) ? 1 : 0;
1712 assert ( iface ==
MMG5_ifar[ia][(ifar_idx+1)%2] );
1723 (*it1) = 4*start + iface;
1726 (*hasadja) = (adja[iface] > 0);
1738 list[(*ilist)] = 6*(int64_t)pradj +pri;
1744 fprintf(stderr,
"\n ## Warning: %s: problem in remesh process."
1745 " Coquil of edge %" MMG5_PRId
"-%" MMG5_PRId
" contains too many elts.\n",
1747 fprintf(stderr,
"\n ## Try to modify the hausdorff number,"
1748 " or/and the maximum mesh.\n");
1754 if (
ier<0 )
return -1;
1755 else if ( !
ier )
continue;
1758 *it2 = 4*pradj+iface;
1765 }
while ( (*adj) && ((*adj) != start) );
1767 if ( (*adj) != start ) {
1791 int8_t *ia,int64_t *list,
int *ilist,MMG5_int *it1,
1792 MMG5_int *pradj,MMG5_int *adj) {
1801 (*adj) = list[(*ilist)-1] / 6;
1802 (*ia) = list[(*ilist)-1] % 6;
1821 *it1 = 4*(*pradj) + (*iface);
1847 MMG5_int *it1,MMG5_int *it2,
int silent) {
1849 MMG5_int piv,adj,na,nb,pradj;
1852 static int8_t mmgErr0=0,mmgErr1=0,mmgWarn0=0;
1861 ier =
MMG3D_coquilFaceFirstLoop(
mesh,start,na,nb,iface,ia,list,&ilist,it1,it2,
1862 &piv,&adj,&hasadja,&nbdy,silent);
1864 if (
ier < 0 )
return ier;
1868 if ( adj == start ) {
1871 printf(
" ## Error: %s: Wrong boundary tags: Only 1 boundary face found in"
1872 " the shell of the edge\n",__func__);
1891 printf(
" ## Warning: %s: you have %d boundary triangles in the closed shell"
1892 " of a manifold edge.\n",__func__,nbdy);
1893 printf(
" Problem may occur during remesh process.\n");
1907 if ( !hasadja )
return 2*ilist+1;
1917 if (
ier<0 )
return -1;
1919 list[ilist] = 6*(int64_t)pradj +i;
1924 fprintf(stderr,
"\n ## Warning: %s: problem in remesh process."
1925 " Coquil of edge %" MMG5_PRId
"-%" MMG5_PRId
" contains too many elts.\n",
1927 fprintf(stderr,
"\n ## Try to modify the hausdorff number,"
1928 " or/and the maximum mesh.\n");
1936 *it2 = 4*pradj + iface;
1938 if ( (!(*it1) || !(*it2)) || ((*it1) == (*it2)) ) {
1963 int8_t *iface, int8_t *i )
2015 int8_t *iface, int8_t *i )
2029 *adj = adja[ *iface ] / 4;
2035 *adj = adja[ *iface ] /4;
if(!ier) exit(EXIT_FAILURE)
int16_t MMG5_coquilTravel(MMG5_pMesh mesh, MMG5_int na, MMG5_int nb, MMG5_int *adj, MMG5_int *piv, int8_t *iface, int8_t *i)
int MMG5_settag(MMG5_pMesh mesh, MMG5_int start, int ia, uint16_t tag, int edg)
int MMG5_boulevolp(MMG5_pMesh mesh, MMG5_int start, int ip, int64_t *list)
Given a vertex and a tetrahedron, find all tetrahedra in the ball of this vertex.
static int MMG3D_settag_oneDir(MMG5_pMesh mesh, MMG5_int start, MMG5_int na, MMG5_int nb, uint16_t tag, int edg, MMG5_int piv, MMG5_int adj)
int MMG5_boulesurfvolp(MMG5_pMesh mesh, MMG5_int start, int ip, int iface, int64_t *listv, int *ilistv, MMG5_int *lists, int *ilists, int isnm)
void MMG3D_coquilFaceSecondLoopInit(MMG5_pMesh mesh, MMG5_int piv, int8_t *iface, int8_t *ia, int64_t *list, int *ilist, MMG5_int *it1, MMG5_int *pradj, MMG5_int *adj)
int MMG3D_findEdge(MMG5_pMesh mesh, MMG5_pTetra pt, MMG5_int k, MMG5_int na, MMG5_int nb, int error, int8_t *mmgWarn, int8_t *ia)
int MMG3D_coquilFaceFirstLoop(MMG5_pMesh mesh, MMG5_int start, MMG5_int na, MMG5_int nb, int8_t iface, int8_t ia, int64_t *list, int *ilist, MMG5_int *it1, MMG5_int *it2, MMG5_int *piv, MMG5_int *adj, int8_t *hasadja, int *nbdy, int silent)
void MMG5_coquilFaceErrorMessage(MMG5_pMesh mesh, MMG5_int k1, MMG5_int k2)
int16_t MMG5_openCoquilTravel(MMG5_pMesh mesh, MMG5_int na, MMG5_int nb, MMG5_int *adj, MMG5_int *piv, int8_t *iface, int8_t *i)
int MMG5_boulenm(MMG5_pMesh mesh, MMG5_int start, int ip, int iface, double n[3], double t[3])
static int MMG3D_deltag_oneDir(MMG5_pMesh mesh, MMG5_int start, MMG5_int na, MMG5_int nb, uint16_t tag, MMG5_int piv, MMG5_int adj)
int MMG5_boulesurfvolpNom(MMG5_pMesh mesh, MMG5_int start, int ip, int iface, int64_t *listv, int *ilistv, MMG5_int *lists, int *ilists, MMG5_int *refmin, MMG5_int *refplus, int isnm)
int MMG5_bouletrid(MMG5_pMesh mesh, MMG5_int start, int iface, int ip, int *il1, MMG5_int *l1, int *il2, MMG5_int *l2, MMG5_int *ip0, MMG5_int *ip1)
int MMG5_srcbdy(MMG5_pMesh mesh, MMG5_int start, int ia)
int MMG5_boulernm(MMG5_pMesh mesh, MMG5_Hash *hash, MMG5_int start, int ip, MMG5_int *ng, MMG5_int *nr, MMG5_int *nm)
int MMG5_deltag(MMG5_pMesh mesh, MMG5_int start, int ia, uint16_t tag)
int MMG5_coquilface(MMG5_pMesh mesh, MMG5_int start, int8_t iface, int ia, int64_t *list, MMG5_int *it1, MMG5_int *it2, int silent)
int MMG5_coquil(MMG5_pMesh mesh, MMG5_int start, int ia, int64_t *list, int8_t *isbdy)
static void MMG3D_compute_tangent(MMG5_pMesh mesh, int nump, int ip0, int ip1, double t[3])
int MMG5_boulenmInt(MMG5_pMesh mesh, MMG5_int start, int ip, double t[3])
API headers and documentation for the mmg3d library, for volumetric meshes in 3D.
static const int8_t MMG5_idirinv[4][4]
MMG5_int MMG3D_indPt(MMG5_pMesh mesh, MMG5_int kp)
static const uint8_t MMG5_arpt[4][3]
arpt[i]: edges passing through vertex i
static const int8_t MMG5_iarf[4][3]
iarf[i]: edges of face opposite to vertex i
static const uint8_t MMG5_iare[6][2]
vertices of extremities of the edges of the tetra
static const uint8_t MMG5_ifar[6][2]
ifar[i][]: faces sharing the ith edge of the tetra
static const uint8_t MMG5_inxt3[7]
next vertex of tetra: {1,2,3,0,1,2,3}
int MMG5_norface(MMG5_pMesh mesh, MMG5_int k, int iface, double v[3])
static const uint8_t MMG5_idir[4][3]
idir[i]: vertices of face opposite to vertex i
MMG5_int MMG3D_indElt(MMG5_pMesh mesh, MMG5_int kel)
static const uint8_t MMG5_iprv2[3]
#define MMG5_TAB_RECALLOC(mesh, ptr, initSize, wantedGap, type, message, law)
#define MG_GET(flag, bit)
static const uint8_t MMG5_inxt2[6]
int MMG5_norpts(MMG5_pMesh, MMG5_int, MMG5_int, MMG5_int, double *)
Identic as MMG5_HGeom but use MMG5_hedge to store edges instead of MMG5_hgeom (memory economy).
Structure to store input parameters of the job.
Structure to store vertices of an MMG mesh.
Structure to store tetrahedra of an MMG mesh.
Used to hash edges (memory economy compared to MMG5_hgeom).
Structure to store additional information for the surface tetrahedra of an MMG mesh.