View Issue Details

IDProjectCategoryView StatusLast Update
0026962CommunityOCCT:Data Exchangepublic2023-03-24 15:34
Reporterjensgw Assigned Togka 
Status newResolutionopen 
PlatformWindowsOSVC++ 2013 
Product Version6.9.1 
Summary0026962: Possible Bug in STEP-Import
DescriptionPlease find attached STEP files and some code which illustrate a possible bug in the STEP Import:
- cylinder.stp has one Assembly which has one Part which has one Cylinder.
- quader.stp has one Assembly which has one Part which has one Box.

What should happen (code below): read a step file, get the shape of a specific entity in the tree - not for the root.
Steps To Reproduce
STEPControl_Reader reader;

Handle(StepData_StepModel) stepModel = reader.StepModel();
Interface_EntityIterator entities = stepModel->Entities();

for (entities.Start(); entities.More(); entities.Next()) {

    Handle(Standard_Transient) value = entities.Value();

    if (value->IsKind("StepShape_ManifoldSolidBrep")) {
        Handle(StepShape_ManifoldSolidBrep) downCast = Handle(StepShape_ManifoldSolidBrep)::DownCast(value);
        Handle(Transfer_TransientProcess) pr = reader.WS()->MapReader();
        //Crashes with cylinder.stp on writing
        //Works with quader.stp on writing
        StepToTopoDS_Builder builder(downCast, pr);
        TopoDS_Shape value2 = builder.Value();
        //Works - but gets shape of root not of specific entity
        //TopoDS_Shape value2 = reader.OneShape();

        STEPControl_Writer writer;
        writer.Transfer(value2, STEPControl_ManifoldSolidBrep);

TagsNo tags attached.
Test case number

Attached Files

  • (5,433 bytes)



2015-12-07 17:39

reporter (5,433 bytes)

Issue History

Date Modified Username Field Change
2015-12-07 17:39 jensgw New Issue
2015-12-07 17:39 jensgw Assigned To => gka
2015-12-07 17:39 jensgw File Added:
2023-03-24 15:34 dpasukhi Steps to Reproduce Updated