How can I get from a list of categories that contain an asset from a DzAsset object?

I want to get a list of the categories to which an asset belongs.  I know how to get hold of assets (how to get the DzAsset object).  I can find everything else I might want to know about the asset by getting the DzMetadata object from the DzAsset, but the DzMetadata object doesn't have categories.

Is there a method on DzAsset that can give me the categories to which the asset belongs?   There's nothing in the SDK documentation or Intellisense, but maybe its just not documented.  The DzAsset script object has userCategories and vendorCategories methods.  I'm looking for the C++ SDK equivalents.

Alternatively, if there is no propety or method on DzAsset that can do this directly, can someone give me an outline of the steps I would follow (from DzAsset to something else to something else and ultimately to the category)?  I don't need C++, pseudo-code is fine, as long as I get some hints on what the "algorithm" should look like

Similarly, can I get from a DzAsset to its product?   There is an example of how to do this in scripting, but I can't see how to translate this to C++.  The example uses a few methods that the SDK doesn't support.

Thanks in advance






  • OK, there's a typo in the title, so let me clarify.  I meant "How can I get a list of categories that contain an asset from a DzAsset object?"   I want to go from an asset to a list of categories to which the asset belongs.  I don't want to go from a list of categories to an asset, which the typo might imply

  • surrealsurreal Posts: 155

    I don't know how to do that using just the SDK. However if it is possible to do using a script then you could get your plugin to run a script that sends the information from the script back to the plugin.

    Embeded in thread   GenerationX provides some example code on how a plugin can execute (class MyClassPane:TestInput()) a script which during its execution calls a subroutine (void MyClassPane:PoseItScriptInput(int In)) of the plugin, to pass information back from that script to the plugin. The example code is about half way down that thread.

  • Thanks surreal, its not ideal but at least it removes the roadblock.  Still interested in any pure C++ suggestions though.

Sign In or Register to comment.