
Search is based on keyword.
Ex: "Procedures"
Do not search with natural language
Ex: "How do I write a new procedure?"
Publishing an Asset
The methods for publishing an Asset in a custom Asset Management System are createAssetAndPath() and postCreateAsset().
createAssetAndPath() creates or updates an asset entry, given a collection of fields and an asset type. It returns the ID of the asset, which resolves to a valid file path. It is invoked prior to writing an asset. The fields passed to createAssetAndPath() may be the result of a decomposed Asset ID stored as a parameter on a node.
Both createAssetAndPath() and postCreateAsset() are used by Katana mechanisms that write assets. The Asset ID returned from createAssetAndPath() is used to create the fields passed to postCreateAsset(). The result from postCreateAsset() is used from that point onward (such as in the File > Open Recent menu or in any references to that asset ID in the current scene):
assetFields1 = assetPlugin.getAssetFields(assetId, True) id1 = assetPlugin.createAssetAndPath(..., assetFields1, ...) [Write Katana project file, for example] assetFields2 = assetPlugin.getAssetFields(id1, True) id2 = assetPlugin.postCreateAsset(..., assetFields2, ...)
This is done to allow a temporary file path to be used for the write operation. The LookFileBake node and the Render node use these methods.
Sorry you didn't find this helpful
Why wasn't this helpful? (check all that apply)
Thanks for your feedback.
If you can't find what you're looking for or you have a workflow question, please try Foundry Support.
If you have any thoughts on how we can improve our learning content, please email the Documentation team using the button below.
Thanks for taking time to give us feedback.