X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FStdMeshers%2FStdMeshers_RadialPrism_3D.cxx;h=23962cba2070d95def31e5867f2d8096784b3f25;hp=17411417e315f49b649a018489b82e7ff8c00b0b;hb=9d73526fbc8ecc160281df9046ad4aed0b57e779;hpb=457be093383be01f6f44d4762e64490e483b7322 diff --git a/src/StdMeshers/StdMeshers_RadialPrism_3D.cxx b/src/StdMeshers/StdMeshers_RadialPrism_3D.cxx index 17411417e..23962cba2 100644 --- a/src/StdMeshers/StdMeshers_RadialPrism_3D.cxx +++ b/src/StdMeshers/StdMeshers_RadialPrism_3D.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2014 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE // // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS @@ -29,8 +29,6 @@ #include "StdMeshers_RadialPrism_3D.hxx" -#include - #include "StdMeshers_ProjectionUtils.hxx" #include "StdMeshers_NumberOfLayers.hxx" #include "StdMeshers_LayerDistribution.hxx" @@ -57,11 +55,7 @@ #include #include #include -#if OCC_VERSION_LARGE > 0x06050400 #include -#else -#include -#endif using namespace std; @@ -169,11 +163,7 @@ bool StdMeshers_RadialPrism_3D::Compute(SMESH_Mesh& aMesh, const TopoDS_Shape& a // get 2 shells TopoDS_Solid solid = TopoDS::Solid( aShape ); -#if OCC_VERSION_LARGE > 0x06050400 TopoDS_Shell outerShell = BRepClass3d::OuterShell( solid ); -#else - TopoDS_Shell outerShell = BRepTools::OuterShell( solid ); -#endif TopoDS_Shape innerShell; int nbShells = 0; for ( TopoDS_Iterator It (solid); It.More(); It.Next(), ++nbShells ) @@ -187,13 +177,13 @@ bool StdMeshers_RadialPrism_3D::Compute(SMESH_Mesh& aMesh, const TopoDS_Shape& a // ---------------------------------- ProjectionUtils::TShapeShapeMap shape2ShapeMaps[2]; - if ( !ProjectionUtils::FindSubShapeAssociation( innerShell, &aMesh, - outerShell, &aMesh, - shape2ShapeMaps[0]) - && - !ProjectionUtils::FindSubShapeAssociation( innerShell.Reversed(), &aMesh, - outerShell, &aMesh, - shape2ShapeMaps[1])) + bool mapOk1 = ProjectionUtils::FindSubShapeAssociation( innerShell, &aMesh, + outerShell, &aMesh, + shape2ShapeMaps[0]); + bool mapOk2 = ProjectionUtils::FindSubShapeAssociation( innerShell.Reversed(), &aMesh, + outerShell, &aMesh, + shape2ShapeMaps[1]); + if ( !mapOk1 && !mapOk2 ) return error(COMPERR_BAD_SHAPE,"Topology of inner and outer shells seems different" ); int iMap; @@ -239,7 +229,7 @@ bool StdMeshers_RadialPrism_3D::Compute(SMESH_Mesh& aMesh, const TopoDS_Shape& a } // Find matching nodes of in and out faces - TNodeNodeMap nodeIn2OutMap; + ProjectionUtils::TNodeNodeMap nodeIn2OutMap; if ( ! ProjectionUtils::FindMatchingNodesOnFaces( inFace, &aMesh, outFace, &aMesh, shape2ShapeMap, nodeIn2OutMap )) return error(COMPERR_BAD_INPUT_MESH,SMESH_Comment("Mesh on faces #") @@ -439,11 +429,7 @@ bool StdMeshers_RadialPrism_3D::Evaluate(SMESH_Mesh& aMesh, { // get 2 shells TopoDS_Solid solid = TopoDS::Solid( aShape ); -#if OCC_VERSION_LARGE > 0x06050400 TopoDS_Shell outerShell = BRepClass3d::OuterShell( solid ); -#else - TopoDS_Shell outerShell = BRepTools::OuterShell( solid ); -#endif TopoDS_Shape innerShell; int nbShells = 0; for ( TopoDS_Iterator It (solid); It.More(); It.Next(), ++nbShells ) @@ -610,7 +596,6 @@ bool StdMeshers_RadialPrism_3D::Evaluate(SMESH_Mesh& aMesh, bool StdMeshers_RadialPrism_3D::IsApplicable( const TopoDS_Shape & aShape, bool toCheckAll ) { - bool isCurShellApp; int nbFoundSolids = 0; for (TopExp_Explorer exp( aShape, TopAbs_SOLID ); exp.More(); exp.Next(), ++nbFoundSolids ) {