2016-10-04 22:30:57 +05:00
|
|
|
#ifndef FILE_SPLINESURFACE
|
|
|
|
#define FILE_SPLINESURFACE
|
|
|
|
|
|
|
|
|
|
|
|
namespace netgen
|
|
|
|
{
|
|
|
|
class SplineSurface : public OneSurfacePrimitive
|
|
|
|
{
|
|
|
|
protected:
|
|
|
|
Array<GeomPoint<3>> geompoints;
|
|
|
|
Array<SplineSeg<3>*> splines;
|
|
|
|
Array<string*> bcnames;
|
|
|
|
|
|
|
|
public:
|
|
|
|
SplineSurface();
|
|
|
|
virtual ~SplineSurface();
|
|
|
|
|
|
|
|
const Array<SplineSeg<3>*> & GetSplines() const { return splines; }
|
|
|
|
int GetNSplines() const { return splines.Size(); }
|
|
|
|
string GetSplineType(const int i) const { return splines[i]->GetType(); }
|
|
|
|
SplineSeg<3> & GetSpline(const int i) { return *splines[i]; }
|
|
|
|
const SplineSeg<3> & GetSpline(const int i) const { return *splines[i]; }
|
|
|
|
int GetNP() const { return geompoints.Size(); }
|
|
|
|
const GeomPoint<3> & GetPoint(int i) const { return geompoints[i]; }
|
|
|
|
string* GetBCName(int i) const { return bcnames[i]; }
|
2016-10-05 22:48:18 +05:00
|
|
|
string* GetBCNameOf(Point<3> p1, Point<3> p2) const;
|
2016-10-04 22:30:57 +05:00
|
|
|
|
|
|
|
DLL_HEADER void AppendPoint(const Point<3> & p, const double reffac = 1., const bool hpref=false);
|
|
|
|
void AppendSegment(SplineSeg<3>* spline, string* bcname);
|
|
|
|
Array<Plane*>* CreatePlanes() const;
|
|
|
|
|
|
|
|
virtual double CalcFunctionValue (const Point<3> & point) const;
|
|
|
|
virtual void CalcGradient (const Point<3> & point, Vec<3> & grad) const;
|
|
|
|
virtual double HesseNorm () const;
|
|
|
|
virtual Point<3> GetSurfacePoint () const;
|
|
|
|
virtual void CalcSpecialPoints(Array<Point<3>> & pts) const;
|
|
|
|
|
|
|
|
virtual INSOLID_TYPE BoxInSolid(const BoxSphere<3> & box) const;
|
|
|
|
|
|
|
|
|
|
|
|
virtual void Print (ostream & str) const;
|
|
|
|
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|