netgen/libsrc/csg/meshsurf.hpp

98 lines
2.5 KiB
C++
Raw Normal View History

2009-01-13 04:40:13 +05:00
#ifndef FILE_MESHSURF
#define FILE_MESHSURF
2009-09-07 17:50:13 +06:00
namespace netgen
2009-01-13 04:40:13 +05:00
{
2009-09-07 17:50:13 +06:00
2009-01-13 04:40:13 +05:00
///
2009-09-07 17:50:13 +06:00
class Meshing2Surfaces : public Meshing2
{
///
const Surface & surface;
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
public:
///
// Meshing2Surfaces (const Surface & asurf);
///
2011-07-25 14:40:23 +06:00
Meshing2Surfaces (const Surface & asurf, const MeshingParameters & mp,
const Box<3> & aboundingbox);
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
protected:
///
virtual void DefineTransformation (const Point3d & p1, const Point3d & p2,
const PointGeomInfo * geominfo1,
const PointGeomInfo * geominfo2);
///
virtual void TransformToPlain (const Point3d & locpoint,
const MultiPointGeomInfo & geominfo,
Point2d & plainpoint,
double h, int & zone);
///
virtual int TransformFromPlain (Point2d & plainpoint,
Point3d & locpoint,
PointGeomInfo & gi,
double h);
///
virtual double CalcLocalH (const Point3d & p, double gh) const;
};
2009-01-13 04:40:13 +05:00
///
2009-09-07 17:50:13 +06:00
class MeshOptimize2dSurfaces : public MeshOptimize2d
{
///
const CSGeometry & geometry;
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
public:
2009-01-13 04:40:13 +05:00
///
MeshOptimize2dSurfaces (const CSGeometry & ageometry);
///
virtual void ProjectPoint (INDEX surfind, Point<3> & p) const;
///
virtual void ProjectPoint2 (INDEX surfind, INDEX surfind2, Point<3> & p) const;
///
virtual void GetNormalVector(INDEX surfind, const Point<3> & p, Vec<3> & n) const;
2009-09-07 17:50:13 +06:00
};
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
class RefinementSurfaces : public Refinement
{
const CSGeometry & geometry;
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
public:
RefinementSurfaces (const CSGeometry & ageometry);
virtual ~RefinementSurfaces ();
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
virtual void PointBetween (const Point<3> & p1, const Point<3> & p2, double secpoint,
int surfi,
const PointGeomInfo & gi1,
const PointGeomInfo & gi2,
2011-01-11 01:18:01 +05:00
Point<3> & newp, PointGeomInfo & newgi) const;
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
virtual void PointBetween (const Point<3> & p1, const Point<3> & p2, double secpoint,
int surfi1, int surfi2,
const EdgePointGeomInfo & ap1,
const EdgePointGeomInfo & ap2,
2011-01-11 01:18:01 +05:00
Point<3> & newp, EdgePointGeomInfo & newgi) const;
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
virtual Vec<3> GetTangent (const Point<3> & p, int surfi1, int surfi2,
const EdgePointGeomInfo & ap1) const;
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
virtual Vec<3> GetNormal (const Point<3> & p, int surfi1,
const PointGeomInfo & gi) const;
2009-01-13 04:40:13 +05:00
2011-01-11 01:18:01 +05:00
virtual void ProjectToSurface (Point<3> & p, int surfi) const;
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
virtual void ProjectToEdge (Point<3> & p, int surfi1, int surfi2, const EdgePointGeomInfo & egi) const;
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
};
2009-01-13 04:40:13 +05:00
2009-09-07 17:50:13 +06:00
}
2009-01-13 04:40:13 +05:00
#endif