MantisBT
Mantis Bug Tracker Workflow

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0027459Community[OCCT] OCCT:Modeling Algorithmspublic2016-05-04 06:382017-12-05 17:01
ReporterVico Liang 
Assigned Tomsv 
PrioritynormalSeveritycrash 
StatusnewResolutionopen 
PlatformWindowsOSVC++ 2013OS Version64 bit
Product Version[OCCT] 6.9.1 
Target Version[OCCT] 7.4.0*Fixed in Version 
Summary0027459: Boolean fuse crash
DescriptionBoolean fuse two solids Body.brep and Cap.brep, the crash stack as below:

     KernelBase.dll!000007fefdc5b3dd() Unknown
     msvcr120d.dll!000007feddabc366() Unknown
     TKernel.dll!Standard_ConstructionError::Throw() Line 10 C++
     TKernel.dll!Standard_Failure::Reraise() Line 153 C++
     TKernel.dll!Standard_Failure::Reraise(const char * const AString) Line 136 C++
     TKernel.dll!Standard_ConstructionError::Raise(const char * const AString) Line 10 C++
> TKBO.dll!BOPTools_AlgoTools2D::MakePCurveOnFace(const TopoDS_Face & aF, const Handle_Geom_Curve & aC3D, const double aT1, const double aT2, Handle_Geom2d_Curve & aC2D, double & TolReached2d) Line 677 C++
     TKBO.dll!BOPTools_AlgoTools2D::Make2D(const TopoDS_Edge & aE, const TopoDS_Face & aF, Handle_Geom2d_Curve & aC2D, double & aFirst, double & aLast, double & aToler) Line 585 C++
     TKBO.dll!BOPTools_AlgoTools2D::CurveOnSurface(const TopoDS_Edge & aE, const TopoDS_Face & aF, Handle_Geom2d_Curve & aC2D, double & aFirst, double & aLast, double & aToler) Line 226 C++
     TKBO.dll!BOPTools_AlgoTools2D::PointOnSurface(const TopoDS_Edge & aE, const TopoDS_Face & aF, const double aParameter, double & U, double & V) Line 181 C++
     TKBO.dll!IsInside(const TopoDS_Shape & theHole, const TopoDS_Shape & theF2, Handle_IntTools_Context & theContext) Line 850 C++
     TKBO.dll!BOPAlgo_BuilderFace::PerformInternalShapes() Line 737 C++
     TKBO.dll!BOPAlgo_BuilderFace::Perform() Line 248 C++
     TKBO.dll!tbb::internal::parallel_for_body<BOPCol_Functor<BOPAlgo_BuilderFace,BOPCol_NCVector<BOPAlgo_BuilderFace> >,int>::operator()(const tbb::blocked_range<int> & r) Line 163 C++
     TKBO.dll!tbb::interface7::internal::partition_type_base<tbb::interface7::internal::auto_partition_type>::execute<tbb::interface7::internal::start_for<tbb::blocked_range<int>,tbb::internal::parallel_for_body<BOPCol_Functor<BOPAlgo_BuilderFace,BOPCol_NCVector<BOPAlgo_BuilderFace> >,int>,tbb::auto_partitioner const >,tbb::blocked_range<int> >(tbb::interface7::internal::start_for<tbb::blocked_range<int>,tbb::internal::parallel_for_body<BOPCol_Functor<BOPAlgo_BuilderFace,BOPCol_NCVector<BOPAlgo_BuilderFace> >,int>,tbb::auto_partitioner const > & start, tbb::blocked_range<int> & range) Line 251 C++
     TKBO.dll!tbb::interface7::internal::start_for<tbb::blocked_range<int>,tbb::internal::parallel_for_body<BOPCol_Functor<BOPAlgo_BuilderFace,BOPCol_NCVector<BOPAlgo_BuilderFace> >,int>,tbb::auto_partitioner const >::execute() Line 128 C++
     tbb_debug.dll!tbb::internal::custom_scheduler<tbb::internal::IntelSchedulerTraits>::local_wait_for_all(tbb::task & parent, tbb::task * child) Line 463 C++
     tbb_debug.dll!tbb::internal::arena::process(tbb::internal::generic_scheduler & s) Line 117 C++
     tbb_debug.dll!tbb::internal::market::process(rml::job & j) Line 495 C++
     tbb_debug.dll!tbb::internal::rml::private_worker::run() Line 276 C++
     tbb_debug.dll!tbb::internal::rml::private_worker::thread_routine(void * arg) Line 229 C++
     [External Code]
Steps To Reproducevoid BOPTools_AlgoTools2D::MakePCurveOnFace
  (const TopoDS_Face& aF,
   const Handle(Geom_Curve)& aC3D,
   const Standard_Real aT1,
   const Standard_Real aT2,
   Handle(Geom2d_Curve)& aC2D,
   Standard_Real& TolReached2d)
{
  Standard_Real aTolR, aT;
  Standard_Real aUMin, aUMax, aVMin, aVMax;
  Handle(Geom2d_Curve) aC2DA;
  Handle(GeomAdaptor_HSurface) aBAHS;
  Handle(GeomAdaptor_HCurve) aBAHC;
  Handle(Geom_Surface) aS;
  //
  BRepAdaptor_Surface aBAS(aF, Standard_True);
  aUMin=aBAS.FirstUParameter();
  aUMax=aBAS.LastUParameter();
  aVMin=aBAS.FirstVParameter();
  aVMax=aBAS.LastVParameter();
  aS=aBAS.Surface().Surface();
  aS=Handle(Geom_Surface)::DownCast(aS->Transformed(aBAS.Trsf()));
  GeomAdaptor_Surface aGAS(aS, aUMin, aUMax, aVMin, aVMax);
  //
  aBAHS=new GeomAdaptor_HSurface(aGAS);
  aBAHC=new GeomAdaptor_HCurve(aC3D, aT1, aT2);
  //
  //when the type of surface is GeomAbs_SurfaceOfRevolution
  if (aGAS.GetType() == GeomAbs_SurfaceOfRevolution) {
    Standard_Real aTR;
    //
    aTR=Precision::Confusion();//1.e-7;
    if (TolReached2d > aTR) {
      aTR=TolReached2d;
    }
    //
    ProjLib_ProjectedCurve aProj1(aBAHS, aBAHC, aTR);
    BOPTools_AlgoTools2D::MakePCurveOfType(aProj1, aC2D);
    aTolR = aProj1.GetTolerance();
  }
  else {
    ProjLib_ProjectedCurve aProjCurv(aBAHS, aBAHC);// 1
    BOPTools_AlgoTools2D::MakePCurveOfType(aProjCurv, aC2D);
    aTolR=aProjCurv.GetTolerance();
  }
  //
  if (aC2D.IsNull()) {
    ProjLib_ProjectedCurve aProjCurvAgain(aBAHS, aBAHC, TolReached2d);// 2
    BOPTools_AlgoTools2D::MakePCurveOfType(aProjCurvAgain, aC2D);
    aTolR = aProjCurvAgain.GetTolerance();
    //
    if (aC2D.IsNull()) {
      Standard_Real aTR=0.0001;
      ProjLib_ProjectedCurve aProj3(aBAHS, aBAHC, aTR);// 3
      BOPTools_AlgoTools2D::MakePCurveOfType(aProj3, aC2D);
      aTolR = aProj3.GetTolerance();
    }
  }
  //
  if(aC2D.IsNull())
  {
    Standard_ConstructionError::Raise("BOPTools_AlgoTools2D::MakePCurveOnFace : PCurve is Null");
  }
TagsNo tags attached.
Test case number
Attached Files? file icon Body.brep (4,088,840 bytes) 2016-05-04 06:38
? file icon Cap.brep (442,637 bytes) 2016-05-04 06:38

- Relationships

-  Notes
There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
2016-05-04 06:38 Vico Liang New Issue
2016-05-04 06:38 Vico Liang Assigned To => msv
2016-05-04 06:38 Vico Liang File Added: Body.brep
2016-05-04 06:38 Vico Liang File Added: Cap.brep
2016-10-28 17:03 msv Target Version 7.1.0 => 7.2.0
2017-07-21 11:34 msv Target Version 7.2.0 => 7.3.0
2017-12-05 17:01 msv Target Version 7.3.0 => 7.4.0*


Copyright © 2000 - 2018 MantisBT Team
Powered by Mantis Bugtracker