Skip to content
Snippets Groups Projects
Commit e07f9b66 authored by Christophe Geuzaine's avatar Christophe Geuzaine
Browse files

extruded boundary layers ok on generic model entities

parent bf72aa99
No related branches found
No related tags found
No related merge requests found
......@@ -1703,6 +1703,8 @@ static int CompareTwoSurfaces(const void *a, const void *b)
!List_Nbr(s1->GeneratricesByTag) && !List_Nbr(s2->GeneratricesByTag))
return 1;
// if generatrices are given bby tag (e.g. for boundary layers on generic
// GModel entities), compare those
if(List_Nbr(s1->GeneratricesByTag) && List_Nbr(s2->GeneratricesByTag))
return Compare2Lists(s1->GeneratricesByTag, s2->GeneratricesByTag, fcmp_absint);
......@@ -2432,6 +2434,17 @@ static void ReplaceDuplicateSurfaces(std::map<int, int> *s_report = nullptr)
else
List_Write(vol->Surfaces, j, ps2);
}
for(int j = 0; j < List_Nbr(vol->SurfacesByTag); j++) {
int num;
List_Read(vol->SurfacesByTag, j, &num);
s2 = FindSurface(std::abs(vol->Extrude->geo.Source), surfaces2delete);
if(s2) {
if(!(ps2 = (Surface **)Tree_PQuery(allNonDuplicatedSurfaces, &s2)))
Msg::Error("Could not replace surface %d in Coherence", s2->Num);
else
List_Write(vol->SurfacesByTag, j, &(*ps2)->Num);
}
}
// replace extrusion sources
if(vol->Extrude && vol->Extrude->geo.Mode == EXTRUDED_ENTITY) {
s2 = FindSurface(std::abs(vol->Extrude->geo.Source), surfaces2delete);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment