Skip to content

Add API call to return metadata struct #1

@selamberson

Description

@selamberson

(This issue was migrated from Kestrel's issue tracker. It was originally posted by Eric Lynch).

It would be really useful if avmeshlib gained the ability to return a persistent object containing all the mesh metadata.  I frequently write scripts to fix problems in meshes (working around bugs in CreateVolumeMesher).  Usually, I don't want to change mesh metadata at all.  However, if I want to write a new mesh file with the same metadata as an old one, I have to make dozens of calls to avmeshlib to retrieve the metadata, one item at a time, then dozens of calls to set it in the new mesh.  It would be awesome if I could do something like:

rv, avid = avmesh.read_headers('in.avm')
rv, meta = avmesh.get_all_metadata(avid)
# At this point, I can look at meta.nNodes or meta.coordinateSystem
# Read heavy data
avmesh.close(avid)
...
# Manipulate connectivity or whatever
...
rv, avid = avmesh.avm_new_file('out.avm')
rv = avmesh.set_all_metadata(avid, meta)
# Write heavy data...
avmesh.close(avid)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions