#include "utilities.h"
-#include <BRepAdaptor_Curve.hxx>
-#include <BRepAdaptor_Curve2d.hxx>
-#include <BRep_Builder.hxx>
#include <BRep_Tool.hxx>
#include <Geom2dAdaptor_Curve.hxx>
#include <Geom2d_Line.hxx>
+#include <TopExp.hxx>
+#include <TopExp_Explorer.hxx>
#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopoDS.hxx>
using namespace std;
-#define RETURN_BAD_RESULT(msg) { MESSAGE(msg); return false; }
+#define RETURN_BAD_RESULT(msg) { MESSAGE(")-: Error: " << msg); return false; }
#define gpXYZ(n) gp_XYZ(n->X(),n->Y(),n->Z())
#define SHOWYXZ(msg, xyz) // {\
// gp_Pnt p (xyz); \
SMESH_Hypothesis::Hypothesis_Status& aStatus)
{
// Check shape geometry
-
+/* PAL16229
aStatus = SMESH_Hypothesis::HYP_BAD_GEOMETRY;
// find not quadrangle faces
if ( nbFace != nbEdge + 2 )
RETURN_BAD_RESULT("Bad nb of faces: " << nbFace << " but must be " << nbEdge + 2);
}
-
+*/
// no hypothesis
aStatus = SMESH_Hypothesis::HYP_OK;
return true;
paramHint = prevTNode.GetParams();
if ( !myBlock.ComputeParameters( bN.GetCoords(), bN.ChangeParams(),
ID_BOT_FACE, paramHint ))
- return error(TCom("Can't compute normalized parameters ")
- << "for node " << botNode->GetID() << " on the face #"<< botSM->GetId() );
+ return error(TCom("Can't compute normalized parameters for node ")
+ << botNode->GetID() << " on the face #"<< botSM->GetId() );
prevTNode = bN;
}
// create node column
paramHint = prevTNode.GetParams();
if ( !myBlock.ComputeParameters( bN.GetCoords(), bN.ChangeParams(),
ID_BOT_FACE, paramHint ))
- return error(TCom("Can't compute normalized parameters ")
- << "for node " << botNode->GetID() << " on the face #"<< botSM->GetId() );
+ return error(TCom("Can't compute normalized parameters for node ")
+ << botNode->GetID() << " on the face #"<< botSM->GetId() );
prevTNode = bN;
// compute top node coords
gp_XYZ topXYZ; gp_XY topUV;
// detect bad cases
if ( nbNotQuad > 0 && nbNotQuad != 2 )
return error(COMPERR_BAD_SHAPE,
- TCom("More than 2 not quadrilateral faces ")
+ TCom("More than 2 not quadrilateral faces: ")
<<nbNotQuad);
if ( nbNotQuadMeshed > 2 )
return error(COMPERR_BAD_INPUT_MESH,
- TCom("More than 2 faces meshed with not quadrangle elements ")
+ TCom("More than 2 faces with not quadrangle elements: ")
<<nbNotQuadMeshed);
// get found submeshes