Read longer names within IGES file

I am trying to read an igs file using OCAF, but can only obtain the shortNames with the following code:

TDF_Label tdfLabel=labels.Value(i);
Handle(TDataStd_Name) name;
tdfLabel.FindAttribute(TDataStd_Name::GetID(), name);

Is there a way to access the full names based on TDF_Labels?

Short names are created in:
analiges.c:void IGES_copstr(char *ligne, int depuis, int tant, char* dans)
with a size of tant=8
What happens with the full string afterwards?

Thank you in advance

Dmitrii Pasukhin's picture


Can you check the correct name on the Inspector (Inspector - Open CASCADE Technology Documentation). Can be build by you or dowloaded with fully installation of OCCT - Download - Open CASCADE Technology. Or with any other document exlorer. Or the best way - sharing the IGES file to check.

If the name exist and correct on the label, you can get it using your code. Please be care that you can get name of reference label of part or own part name.

Best regards, Dmitrii

Thomas Hafemann's picture

Hi Dmitrii,
thanks for the fast answer. I still have to give Inspector a try. Unfortunately, I'm on linux.

Checking the IGES file, I saw that the full name is stored as a Type 406, Form 15 object. The same name is also visible at the named surface (144)

The IGESCAFReader will do two things:
- Read the 406 entity with the long name
- Read the 144 entity with only 8 characteres. The remaining characteres land on the Subscript, which then is substituted by "(0)" at some point.

During binding, only shape entities are binded, so that the 406 is not used.
While checking for the name, theform object of the surface (144) is Null, so that the function uses the ShortLabel.

I could not understand how to get a Link between the 406 entity and the 144 entity.
Thanks in advance,
Best regards, Thomas