How to set id on MANIFOLD_SOLID_BREP ?

Hello All,

I need to set the id on some STEP entities, most notably Product and MANIFOLD_SOLID_BREP.

I managed to set the product name using

 Handle(TDocStd_Document) document;
    document = new TDocStd_Document("hole request document");
    Handle(XCAFDoc_ShapeTool) shapeTool;
    shapeTool = XCAFDoc_DocumentTool::ShapeTool(document->Main());
    TDF_Label productLabel = shapeTool->AddShape(newHole, Standard_False);
    
    Handle(TDataStd_Name) name;
    productLabel.FindAttribute(TDataStd_Name::GetID(), name);
    if (!name.IsNull()) {        
        name->Set("myName");
    }

but terribly fail to set the id on the MANIFOLD_SOLID_BREP.

Is there some lowlevel API to access to the STEP entities before writing them to a file ?

Alternatively, is it possible to get the TDF_labels for that entity ?

Thanks, Carsten

魏涛 魏's picture

Hi:

How do you solve it? I wang set a name to Entity(like face).