Throw Exception if ProjectPointGI is not implemented

This commit is contained in:
Matthias Hochsteger 2019-10-23 11:26:45 +02:00
parent 22a894b8cf
commit eaf2bee9e6

View File

@ -51,9 +51,9 @@ namespace netgen
virtual bool CalcPointGeomInfo(int surfind, PointGeomInfo& gi, const Point<3> & p3) const {return false;} virtual bool CalcPointGeomInfo(int surfind, PointGeomInfo& gi, const Point<3> & p3) const {return false;}
virtual bool ProjectPointGI (int surfind, Point<3> & p, PointGeomInfo & gi) const virtual bool ProjectPointGI (int surfind, Point<3> & p, PointGeomInfo & gi) const
{ {
ProjectPoint(surfind, p); throw Exception("ProjectPointGI not overloaded in class" + Demangle(typeid(*this).name()));
return CalcPointGeomInfo(surfind, gi, p);
} }
virtual Vec<3> GetNormal(int surfind, const Point<3> & p) const virtual Vec<3> GetNormal(int surfind, const Point<3> & p) const
{ return {0.,0.,1.}; } { return {0.,0.,1.}; }
virtual Vec<3> GetNormal(int surfind, const Point<3> & p, const PointGeomInfo & gi) const virtual Vec<3> GetNormal(int surfind, const Point<3> & p, const PointGeomInfo & gi) const