DiscussionsIssue archiveData Exchange and Application Framework

Archived discussion

Error while loading the vrml file.

Data Exchange and Application FrameworkMon, 10/06/2025 - 15:059 replies

Browse this forum
QuestionAuthor

I’m working with a VRML model and ran into an import issue using Open Cascade 7.7.

My VRML file contains data like this:

```
MaterialBinding {
value PER_FACE_INDEXED
}
Material {
ambientColor [
0.752941 0.752941 0.752941
]
diffuseColor [
0.752941 0.752941 0.752941
]
emissiveColor [
0.158118 0.158118 0.158118
]
specularColor [
0.662588 0.662588 0.662588
]
shininess [
0.210000
]
transparency [
0.000000
]
}
```

The first issue is that when reading the `ambientColor` node, the parser only recognizes the opening line (`ambientColor [`) but does not capture the values on the following lines until the closing bracket. I’ve made some changes in the source code to work around this, but parsing still fails because Open Cascade 7.7 does not support the `ambientColor` node at all.

My questions are:

1. Which VRML nodes are unsupported in Open Cascade 7.7?
2. Are these nodes supported in newer versions, such as 7.9?

Any guidance or documentation references would be greatly appreciated.

Discussion

9 archived replies

Posts are displayed in their archived order.

01Commenter-1

OCCT version 7.8 and 7.9 have support for ambientColor node.

Patch: 0033426 https://github.com/Open-Cascade-SAS/OCCT/commit/06f2625c35e9a8897ad49898...

Best regards, Commenter-1.

02Author

Thank you.
Also, in some cases, I observed that the buffer reads only the line "ambientColor [", "materialIndex ["
If the array values are written on the next line, they are not recognized, and the parser throws a VrmlData_VrmlFormatError.
I have attached reference image

03Commenter-1

In case of problems - it is better to share the file samples to reproduce from our side.

Best regards, Commenter-1.

04Author

I have upgraded to version 7.9.1
but While importing vrml files
code break when reading "materialIndex"

05Author

Here are the model which have issues

06Author

Any update on this

07Commenter-1

Bug reports which shared only on the forum is low priority and can be not fixed because they were forgotten.

Please report the bug in GitHub issues: https://github.com/Open-Cascade-SAS/OCCT/issues/new/choose

Best regards, Commenter-1.

08Author

Okay. I will report the bug on GitHub

09Author

Could you please let me know which VRML node types are supported in Open Cascade 7.9, and which VRML versions (e.g., 1.0 or 2.0) are compatible?