mirror of
https://github.com/NGSolve/netgen.git
synced 2024-12-25 21:40:33 +05:00
Merge branch 'add_csg_solid_maxh' into 'master'
Add maxh property to Solid2d See merge request jschoeberl/netgen!464
This commit is contained in:
commit
8e38334b9a
@ -2185,6 +2185,7 @@ shared_ptr<netgen::SplineGeometry2d> CSG2d :: GenerateSplineGeometry()
|
|||||||
if(!is_solid_degenerated)
|
if(!is_solid_degenerated)
|
||||||
{
|
{
|
||||||
geo->SetMaterial(dom, s.name);
|
geo->SetMaterial(dom, s.name);
|
||||||
|
geo->SetDomainMaxh(dom, s.maxh);
|
||||||
if(s.layer != 1)
|
if(s.layer != 1)
|
||||||
geo->SetDomainLayer(dom, s.layer);
|
geo->SetDomainLayer(dom, s.layer);
|
||||||
}
|
}
|
||||||
|
@ -632,6 +632,7 @@ struct Solid2d
|
|||||||
|
|
||||||
int layer = 1;
|
int layer = 1;
|
||||||
string name = MAT_DEFAULT;
|
string name = MAT_DEFAULT;
|
||||||
|
double maxh = MAXH_DEFAULT;
|
||||||
|
|
||||||
Solid2d() = default;
|
Solid2d() = default;
|
||||||
Solid2d(string name_) : name(name_) {}
|
Solid2d(string name_) : name(name_) {}
|
||||||
@ -697,6 +698,7 @@ struct Solid2d
|
|||||||
|
|
||||||
Solid2d & Maxh(double maxh)
|
Solid2d & Maxh(double maxh)
|
||||||
{
|
{
|
||||||
|
this->maxh = maxh;
|
||||||
for(auto & p : polys)
|
for(auto & p : polys)
|
||||||
for(auto v : p.Vertices(ALL))
|
for(auto v : p.Vertices(ALL))
|
||||||
v->info.maxh = maxh;
|
v->info.maxh = maxh;
|
||||||
|
Loading…
Reference in New Issue
Block a user