Qt Quick 3d RuntimeLoader nodes do not hold names and extras from the assimp aiNodes derived from GLTF2 model
-
Hi,
I'm loading a gltf2 model (exported from Blender) at runtime, using RuntimeLoader.The exported gltf2 file contains for each node:
- name, the Id of node
- extras, the custom properties associated in Blender for each node
e.g.
{
"extras":{
"scatter5":{ "estimated_square_area":0.0019120166543871164},
"HG":{},
"myCustomProperty":"prop"
},
"mesh":21,
"name":"Curve.004",
"translation":[
-5.14517068862915,
0,
5.236505031585693
]
}Using RuntimeLoader:
The name property is not reported in the objectName of created models.
The extras property is ignored.
While debugging, I noticed that the aiNodes created by assimp lib report both information in the mName and mMetaData properties respectively.
I noticed that, after scene creation using QSSGRuntimeUtils::createScene(*m_root, scene) in qquick3druntimeloader.cpp, properties are not reported in QtQuick3d data structures.Basically I would need to retrieve the identifier (name) and custom properties (extras) associated with the node when I make a pick on it, in order to distinguish the part of the model with which I am interacting.
I also tried other ways to use gltf2 models.
In particular I tried the recommended way to convert from gltf2 to qml using both QtDesignStudio and Balsam.
In both cases, strangely, the created qml Models show the objectName correctly evaluated with the value of the name property, but there is no trace of the extras.Is it a gap in the framework or is there a way I don't know?
Thanks,
Best regards