addAssetLibrary#

Fully qualified name: usdex::core::addAssetLibrary

pxr::UsdStageRefPtr usdex::core::addAssetLibrary(
pxr::UsdStagePtr stage,
const std::string &name,
const std::string &format = "usdc",
const pxr::SdfLayer::FileFormatArguments &fileFormatArgs = pxr::SdfLayer::FileFormatArguments(),
)#

Create a Library Layer from which the Content Layers can reference prims.

This layer will contain a library of meshes, materials, prototypes for instances, or anything else that can be referenced by the Content Layers. It is not intended to be used as a standalone layer. The default prim will have a class specifier.

Parameters:
  • stage – The stage’s edit target identifier will dictate where the Library Layer will be created

  • name – The name of the library (e.g., “Geometry”, “Materials”)

  • format – The file format extension (default: “usdc”)

  • fileFormatArgs – Additional file format-specific arguments to be supplied during stage creation.

Returns:

The newly created relative layer opened as a new stage. It will be named “<name>Library.<format>”