View Issue Details

IDProjectCategoryView StatusLast Update
0033604CommunityOCCT:Modeling Algorithmspublic2024-06-07 14:13
Reporterhwliu11 Assigned To 
PrioritynormalSeveritycrash 
Status assignedResolutionopen 
PlatformWindowsOSVC++ 2017 
Product Version7.8.0 
Target VersionUnscheduled 
Summary0033604: Modeling Algorithms - GeomFill_Pipe cause mfc samples crash
Descriptioncrash file samples\mfc\standard\01_Geometry GeomSources::gpTest40 line 3144,the version 7.6 work well,it like that function void GeomFill_Pipe::Init(const Handle(Geom_Curve)& Path, const Handle(Geom_Curve)& FirstSect,const Handle(Geom_Curve)& LastSect) not set correct flags,7.6 is myLoc->SetCurve(myAdpPath),not check the result,but 7.7 and above,
  if (!(myLoc->SetCurve(myAdpPath)))
   {
     myStatus = GeomFill_ImpossibleContact;
     return;
   }

run into this line myStatus = GeomFill_ImpossibleContact and return,so Performe throw exception
TagsNo tags attached.
Test case number

Activities

dpasukhi

2024-02-18 13:40

administrator   ~0115123

Dear @hwliu11 could you share a file to reproduce and full scenario that you perform.

hwliu11

2024-02-19 05:06

reporter   ~0115135

void GeomSources::gpTest40(CGeometryDoc* aDoc)
{
  DisplayType TheDisplayType = No2D3D;
  PreProcess(aDoc,TheDisplayType);
  //==============================================================

  TColgp_Array1OfPnt array1 (1,5); // sizing array
  array1.SetValue(1,gp_Pnt (-4,0,2 ));
  array1.SetValue(2,gp_Pnt (-5,1,0 ));
  array1.SetValue(3,gp_Pnt (-6,2,-2 ));
  array1.SetValue(4,gp_Pnt (-5,4,-7));
  array1.SetValue(5,gp_Pnt (-3,5,-12));

  Handle(Geom_Curve) SPL1 =
  GeomAPI_PointsToBSpline(array1).Curve();

  GeomFill_Pipe aPipe(SPL1,1);
  aPipe.Perform();
  Handle(Geom_Surface) aSurface= aPipe.Surface();
  Standard_CString aSurfaceEntityTypeName="Not Computed";
  if (!aSurface.IsNull())
  aSurfaceEntityTypeName = aSurface->DynamicType()->Name();

  Handle(Geom_Ellipse) E = GC_MakeEllipse( gp::XOY() ,3,1).Value();
  GeomFill_Pipe aPipe2(SPL1,E);
  aPipe2.Perform();
  Handle(Geom_Surface) aSurface2= aPipe2.Surface();
  Standard_CString aSurfaceEntityTypeName2="Not Computed";
  if (!aSurface2.IsNull()) {
  aSurfaceEntityTypeName2 = aSurface2->DynamicType()->Name();
  aSurface2->Translate(gp_Vec(5,0,0)); }

  Handle(Geom_TrimmedCurve) TC1 =
  GC_MakeSegment(gp_Pnt(1,1,1),gp_Pnt(5,5,5));
  Handle(Geom_TrimmedCurve) TC2 =
  GC_MakeSegment(gp_Pnt(1,1,0),gp_Pnt(4,5,6));
  GeomFill_Pipe aPipe3(SPL1,TC1,TC2);
  aPipe3.Perform();
  Handle(Geom_Surface) aSurface3 = aPipe3.Surface();
  Standard_CString aSurfaceEntityTypeName3="Not Computed";
  if (!aSurface3.IsNull())
  {
  aSurfaceEntityTypeName3 = aSurface3->DynamicType()->Name();
  aSurface3->Translate(gp_Vec(10,0,0));
  }
}
the main code for the function
the bug reproduce with mfc sample Geometry
I have the py code.not tcl.
array1=OCC.TColgp_Array1OfPnt(1,5)
array1.SetValue(1,OCC.gp_Pnt(-4,0,2))
array1.SetValue(2,OCC.gp_Pnt(-5,1,0))
array1.SetValue(3,OCC.gp_Pnt(-6,2,-2))
array1.SetValue(4,OCC.gp_Pnt(-5,4,-7))
array1.SetValue(5,OCC.gp_Pnt(-3,5,-12))

TC1 =OCC.GC_MakeSegment(OCC.gp_Pnt(1,1,1),OCC.gp_Pnt(5,5,5)).Value()
TC2 =OCC.GC_MakeSegment(OCC.gp_Pnt(1,1,0),OCC.gp_Pnt(4,5,6)).Value()

aPipe3=OCC.GeomFill_Pipe(SPL1,TC1,TC2);
aPipe3.Perform();

Issue History

Date Modified Username Field Change
2024-02-18 12:12 hwliu11 New Issue
2024-02-18 12:12 hwliu11 Assigned To => anv
2024-02-18 13:36 dpasukhi Severity minor => crash
2024-02-18 13:36 dpasukhi Target Version => Unscheduled
2024-02-18 13:36 dpasukhi Summary GeomFill_Pipe cause mfc samples crash => Samples - GeomFill_Pipe cause mfc samples crash
2024-02-18 13:36 dpasukhi Description Updated
2024-02-18 13:40 dpasukhi Note Added: 0115123
2024-02-18 13:40 dpasukhi Assigned To anv => hwliu11
2024-02-18 13:40 dpasukhi Status new => acknowledged
2024-02-19 05:06 hwliu11 Note Added: 0115135
2024-02-20 04:45 hwliu11 Assigned To hwliu11 => dpasukhi
2024-02-20 12:39 dpasukhi Status acknowledged => assigned
2024-02-20 12:40 dpasukhi Category OCCT:Samples => OCCT:Modeling Algorithms
2024-02-20 12:41 dpasukhi Assigned To dpasukhi => akaftasev
2024-02-20 12:41 dpasukhi Summary Samples - GeomFill_Pipe cause mfc samples crash => Modeling Algorithms - GeomFill_Pipe cause mfc samples crash
2024-06-07 14:13 akaftasev Assigned To akaftasev =>