GUI metadata using

Hi!

I was sight not pretty strange behaviour in GUI.
After add Control3D to GUI Manager all metadata in Mesh is changed (setted in to MeshButton3D object).

I was think metadata is common section, and developer can use this whithout fear lost own data.
I suggest change this behavior of GUI - get only one or some elements (keys) of metadata (as example use GUI key).
This solution will not dirty space of metadata and save high flexibility for developer.

As example:
Object:Mesh
— metadata:any
------ GUI:MeshButton3D // here is GUI territory
------ data any kind 1:boolean
------ data any kind 2:string

Problem Illustration:

p. s. Can you advice where topic with user-voice or somthing like this please. Or right topic for suggestions, like this. It was be before, but i can’t find that (

I agree that this might conflict with your own need.

@Evgeni_Popov any quick idea we could do ? maybe metadata.GUI ???

Yes, adding a subsection for gui would work (I would use GUI3D instead of GUI, though), but I wonder if using the metadata entry is the right thing to do… As per the doc, the metadata property is a property used to store user defined information, so I don’t think the user should expect the system to store internal data there.

I think at start (when GUI3D has been developped) the node holding the meta data was created by the GUI3D itself, so it was an internal node and it was legit to use the metadata property. But at some point MeshButton3D has been added and instead of creating an internal node it is using the mesh passed to the constructor, and then overwrites its metadata property (all its submeshes have also their metadata property overwritten).

I don’t know what could be the solution if we don’t want to use the metadata property. Maybe adding a _internalTransformNodeDataInfo to TransformNode in the same way we have a _internalAbstractMeshDataInfo in AbstractMesh but TransformNode is used everywhere, so adding this property only for this use case may be overkill…

Here’s what it looks like using the metadata property:

Evgeni, sebavan thank you very much for help and attention!

1 Like