[step/Iges] Get the names and colors of the different shapes

Hi,
I'm developping a step/iges viewer and I would like to get the informations about the different shapes including in the step/iges file : color, name of the different shapes. Is it possible to get these with OCC or not ? When I open a step file with Notepad, for example, I can read these labels : OCC can do that ?
Thank you for your answers, have a nice afternoon.
Jc.

Jérome Dufaure's picture

hi
you can have a look to the packages IGESCAFControl_Reader, STEPCAFControl_Reader. These packages allow to read name and color of shapes contained in step and iges files. I hope this will help you.

jclgarou's picture

Ok, thank you !
But do you know wich function allows to get the names of shapes in the STEPCAFControl_Reader package. I'm looking for in the doc of OpenCascade, I'm not finding something...
I'm ok with the initialization :
STEPCAFControl_Reader reader;
IFSelect_ReturnStatus status = reader.ReadFile(stepFile);
But after, how to get the names, I don't know. If somebody has already done it, thank you for your help !

Jc.