Imported metadata now uses Attribute tables

Prior to Visionary Render 2.0, CAD metadata on parts was stored in a tree structure on each assembly:

This resulted in a significant memory and processing overhead, causing files with a lot of metadata to load slower, perform worse, and use more disk space.

Since Visionary Render 2.0, metadata from imports is now stored in a table structure called an AttributeTable. Instead of one node per key-value pair, the Attribute Table contains all of this information:

This results in a much more optimal handling of the metadata and results in much improved loading and performance, however it comes with some caveats in terms of flexibility:

  1. It is not possible to add or remove rows to these tables - however keys and value data can be renamed
  2. All keys and values are strings
  3. Some usage of the Lua API will no longer work if the script is assuming that metadata values are children of the MetaGroup (container) node

    The metadata access syntax node.Metadata.Key  and node.Metadata["key"] are compatible with both types of metadata storage. The latter should be used if the keys contain spaces.

    For example, setting the text of a label from a script attached to it: __Self.Text = node.Metadata["my attribute"]

If you have utility scripts that you reuse to access metadata in a way other than the compatible method listed above (3.a), you may have to update your scripts to conform to this.

Details about working with attribute tables can be found in the programming guide

J
Jamie is the author of this solution article.

Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.