2009-01-13 04:40:13 +05:00
|
|
|
#include <mystdlib.h>
|
|
|
|
|
|
|
|
#include <csg.hpp>
|
|
|
|
#include <meshing.hpp>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
namespace netgen
|
|
|
|
{
|
|
|
|
/*
|
|
|
|
Meshing2Surfaces :: Meshing2Surfaces (const Surface & asurface)
|
|
|
|
: surface(asurface)
|
|
|
|
{
|
|
|
|
;
|
|
|
|
}
|
|
|
|
*/
|
|
|
|
Meshing2Surfaces :: Meshing2Surfaces (const Surface & asurf,
|
2011-07-25 14:40:23 +06:00
|
|
|
const MeshingParameters & mp,
|
2009-01-13 04:40:13 +05:00
|
|
|
const Box<3> & abb)
|
2014-08-30 06:15:59 +06:00
|
|
|
: Meshing2(mp, abb), surface(asurf), mparam (mp)
|
2009-01-13 04:40:13 +05:00
|
|
|
{
|
|
|
|
;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2019-09-29 17:54:24 +05:00
|
|
|
void Meshing2Surfaces :: DefineTransformation (const Point<3> & p1, const Point<3> & p2,
|
2009-01-13 04:40:13 +05:00
|
|
|
const PointGeomInfo * geominfo1,
|
|
|
|
const PointGeomInfo * geominfo2)
|
|
|
|
{
|
|
|
|
((Surface&)surface).DefineTangentialPlane (p1, p2);
|
|
|
|
}
|
|
|
|
|
2019-09-29 17:54:24 +05:00
|
|
|
void Meshing2Surfaces :: TransformToPlain (const Point<3> & locpoint,
|
2009-01-13 04:40:13 +05:00
|
|
|
const MultiPointGeomInfo & geominfo,
|
2019-09-29 17:54:24 +05:00
|
|
|
Point<2> & planepoint,
|
2009-01-13 04:40:13 +05:00
|
|
|
double h, int & zone)
|
|
|
|
{
|
2019-09-29 17:54:24 +05:00
|
|
|
surface.ToPlane (locpoint, planepoint, h, zone);
|
2009-01-13 04:40:13 +05:00
|
|
|
}
|
|
|
|
|
2019-09-29 17:54:24 +05:00
|
|
|
int Meshing2Surfaces :: TransformFromPlain (const Point<2> & planepoint,
|
|
|
|
Point<3> & locpoint,
|
|
|
|
PointGeomInfo & gi,
|
|
|
|
double h)
|
2009-01-13 04:40:13 +05:00
|
|
|
{
|
2019-09-29 17:54:24 +05:00
|
|
|
surface.FromPlane (planepoint, locpoint, h);
|
2009-01-13 04:40:13 +05:00
|
|
|
gi.trignum = 1;
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-10-01 14:59:17 +05:00
|
|
|
double Meshing2Surfaces :: CalcLocalH (const Point<3> & p, double gh) const
|
2009-01-13 04:40:13 +05:00
|
|
|
{
|
2014-08-30 06:15:59 +06:00
|
|
|
return surface.LocH (p, 3, 1, mparam, gh);
|
2009-01-13 04:40:13 +05:00
|
|
|
/*
|
|
|
|
double loch = mesh.lochfunc->GetH(p);
|
|
|
|
if (gh < loch) loch = gh;
|
|
|
|
return loch;
|
|
|
|
*/
|
|
|
|
}
|
|
|
|
}
|