-// Copyright (C) 2007-2021 CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2024 CEA, EDF, OPEN CASCADE
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
#include <SMESH_Comment.hxx>
#include <SMESH_Gen.hxx>
#include <SMESH_Mesh.hxx>
+#include <SMESH_SequentialMesh.hxx>
#include <SMESH_MeshAlgos.hxx>
#include <SMESH_MeshEditor.hxx>
#include <SMESH_MesherHelper.hxx>
#include <GeomAPI_ExtremaCurveCurve.hxx>
#include <GeomAPI_ProjectPointOnSurf.hxx>
#include <GeomAdaptor_Curve.hxx>
+#include <GeomAdaptor_Surface.hxx>
+
+#include <Basics_OCCTVersion.hxx>
+
+#if OCC_VERSION_LARGE < 0x07070000
#include <GeomAdaptor_HCurve.hxx>
#include <GeomAdaptor_HSurface.hxx>
-#include <GeomAdaptor_Surface.hxx>
+#endif
+
#include <GeomLib_IsPlanarSurface.hxx>
#include <Geom_Line.hxx>
#include <IntCurveSurface_HInter.hxx>
break;
}
case TopAbs_EDGE: {
-
+
// Get submeshes of sub-vertices
const map< int, SMESH_subMesh * >& subSM = sm->DependsOn();
if ( subSM.size() != 2 )
while ( elemIt->more() ) // loop on all mesh faces on srcFace
{
const SMDS_MeshElement* elem = elemIt->next();
- const int nbN = elem->NbCornerNodes();
+ const int nbN = elem->NbCornerNodes();
tgtNodes.resize( nbN );
helper->SetElementsOnShape( false );
for ( int i = 0; i < nbN; ++i ) // loop on nodes of the source element
*/
//================================================================================
- struct QuadMesh : public SMESH_Mesh
+ struct QuadMesh : public SMESH_SequentialMesh
{
ObjectPool< TriaCoordSys > _traiLCSPool;
SMESH_ElementSearcher* _elemSearcher;
// const SMDS_MeshElement* elem = elemIt->next();
// TFaceConn& tgtNodes = newFacesVec[ iFaceSrc++ ];
- // const int nbN = elem->NbCornerNodes();
+ // const int nbN = elem->NbCornerNodes();
// tgtNodes.resize( nbN );
// for ( int i = 0; i < nbN; ++i ) // loop on nodes of the source element
// {
// {
// tgtNodeOrXY.first = srcN_tgtN->second; // tgt node exists
// }
- // else
+ // else
// {
// // find XY of src node within the quadrilateral srcFace
// if ( !block.ComputeParameters( SMESH_TNodeXYZ( srcNode ),
SMESHDS_Mesh* tgtMeshDS = tgtMesh->GetMeshDS();
Handle(Geom_Surface) tgtSurface = BRep_Tool::Surface( theTgtFace );
+#if OCC_VERSION_LARGE < 0x07070000
Handle(GeomAdaptor_HSurface) tgtSurfAdaptor = new GeomAdaptor_HSurface( tgtSurface );
Handle(GeomAdaptor_HCurve) piercingCurve = new GeomAdaptor_HCurve( thePiercingLine );
+#else
+ Handle(GeomAdaptor_Surface) tgtSurfAdaptor = new GeomAdaptor_Surface( tgtSurface );
+ Handle(GeomAdaptor_Curve) piercingCurve = new GeomAdaptor_Curve( thePiercingLine );
+#endif
IntCurveSurface_HInter intersect;
SMESH_MesherHelper* srcHelper = theSrcWires[0]->FaceHelper();
TAssocTool::Morph morph( srcWires );
morph.Perform( helper, tgtWires, helper.GetSurface( tgtFace ),
_src2tgtNodes, /*moveAll=*/true );
-#ifdef _DEBUG_
- cout << "StdMeshers_Projection_2D: Projection mesh IsDistorted2D() ==> do morph" << endl;
-#endif
+ if(SALOME::VerbosityActivated())
+ cout << "StdMeshers_Projection_2D: Projection mesh IsDistorted2D() ==> do morph" << endl;
if ( !fixDistortedFaces( helper, tgtWires )) // smooth and check
return error("Invalid mesh generated");