]> SALOME platform Git repositories - modules/geom.git/commitdiff
Salome HOME
fix for test cases bugs_13/N8 and imps_04/E5
authorskv <skv@opencascade.com>
Thu, 23 Apr 2015 08:36:19 +0000 (11:36 +0300)
committerskv <skv@opencascade.com>
Thu, 23 Apr 2015 08:36:19 +0000 (11:36 +0300)
src/GEOMImpl/GEOMImpl_BooleanDriver.cxx

index 5c0812760ea6b7ce172836291bc08dc63dedf26d..4d6a72f2abb8358fbea33ded131924e70bf312ed 100644 (file)
@@ -548,71 +548,6 @@ TopoDS_Shape GEOMImpl_BooleanDriver::performOperation
   if ( !GEOMUtils::CheckShape(aShape, true) && !GEOMUtils::FixShapeTolerance(aShape) )
     Standard_ConstructionError::Raise("Boolean operation aborted : non valid shape result");
 
-  // BEGIN: Mantis issue 0021060: always limit tolerance of BOP result
-  // 1. Get shape parameters for comparison
-  int nbTypes [TopAbs_SHAPE];
-  {
-    for (int iType = 0; iType < TopAbs_SHAPE; ++iType)
-      nbTypes[iType] = 0;
-    nbTypes[aShape.ShapeType()]++;
-
-    TopTools_MapOfShape aMapOfShape;
-    aMapOfShape.Add(aShape);
-    TopTools_ListOfShape aListOfShape;
-    aListOfShape.Append(aShape);
-
-    TopTools_ListIteratorOfListOfShape itL (aListOfShape);
-    for (; itL.More(); itL.Next()) {
-      TopoDS_Iterator it (itL.Value());
-      for (; it.More(); it.Next()) {
-        TopoDS_Shape s = it.Value();
-        if (aMapOfShape.Add(s)) {
-          aListOfShape.Append(s);
-          nbTypes[s.ShapeType()]++;
-        }
-      }
-    }
-  }
-
-  // 2. Limit tolerance
-  TopoDS_Shape aShapeCopy;
-  TColStd_IndexedDataMapOfTransientTransient aMapTShapes;
-  TNaming_CopyShape::CopyTool(aShape, aMapTShapes, aShapeCopy);
-
-  if ( GEOMUtils::FixShapeTolerance(aShapeCopy, true) ) {
-    int iType, nbTypesCopy [TopAbs_SHAPE];
-
-    for (iType = 0; iType < TopAbs_SHAPE; ++iType)
-      nbTypesCopy[iType] = 0;
-    nbTypesCopy[aShapeCopy.ShapeType()]++;
-
-    TopTools_MapOfShape aMapOfShape;
-    aMapOfShape.Add(aShapeCopy);
-    TopTools_ListOfShape aListOfShape;
-    aListOfShape.Append(aShapeCopy);
-
-    TopTools_ListIteratorOfListOfShape itL (aListOfShape);
-    for (; itL.More(); itL.Next()) {
-      TopoDS_Iterator it (itL.Value());
-      for (; it.More(); it.Next()) {
-        TopoDS_Shape s = it.Value();
-        if (aMapOfShape.Add(s)) {
-          aListOfShape.Append(s);
-          nbTypesCopy[s.ShapeType()]++;
-        }
-      }
-    }
-
-    bool isEqual = true;
-    for (iType = 0; iType < TopAbs_SHAPE && isEqual; ++iType) {
-      if (nbTypes[iType] != nbTypesCopy[iType])
-        isEqual = false;
-    }
-    if (isEqual)
-      aShape = aShapeCopy;
-  }
-  // END: Mantis issue 0021060
-
   return aShape;
 }