usdrt::UsdRenderSettingsAPI

Defined in usdrt/scenegraph/usd/usdRender/settingsAPI.h

Functions

Variables

class UsdRenderSettingsAPI : public usdrt::UsdAPISchemaBase

UsdRenderSettingsAPI is a base class for API schemas to encode renderer-specific settings.

Single vs. Multiple Apply API Schemas

Applied API schemas can further be classified into single-apply and multiple-apply API schemas. As the name suggests, a single-apply API schema can only be applied once to a prim. A multiple-apply API schema can be applied multiple times with different ‘instanceName’ values. An example of a multiple-apply API schema is UsdCollectionAPI, where the API schema is applied to a prim once for every collection owned by the prim.

Note

An applied API schema can only inherit from another applied API schema or directly from APISchemaBase. Similarly, a non-applied API schema can only inherit from a non-applied API Schema or directly from APISchemaBase. ‘usdGenSchema’ attempts to issue a warning if it detects an incompatibility.

Note

A multiple-apply API schema may not inherit from a single-apply API schema and vice versa.

Note

When the bool-conversion operator is invoked on an applied API schema, it evaluates to true only if the application of the API schema has been recorded on the prim via a call to the auto-generated Apply() method.

inline operator bool() const

Boolean operator.

Returns

Return true if the contained prim is an instance of this schema using IsA, and false otherwise.

Public Functions

inline explicit UsdRenderSettingsAPI(const UsdPrim &prim = UsdPrim())

Construct a UsdRenderSettingsAPI on UsdPrim prim . Equivalent to UsdRenderSettingsAPI::Get(prim.GetStage(), prim.GetPath()) for a valid prim, but will not immediately throw an error for an invalid prim.

inline explicit UsdRenderSettingsAPI(const UsdSchemaBase &schemaObj)

Construct a UsdRenderSettingsAPI on the prim held by schemaObj . Should be preferred over UsdRenderSettingsAPI(schemaObj.GetPrim()), as it preserves SchemaBase state.

inline virtual ~UsdRenderSettingsAPI()

Destructor.

UsdPrim GetPrim() const

Return this schema object’s held prim.

SdfPath GetPath() const

Return the SdfPath to this schema object’s held prim.

Public Static Functions

static inline const TfToken _GetStaticTfType()

Public Static Attributes

static const UsdSchemaType schemaType = UsdSchemaType::SingleApplyAPI

Compile time constant representing what kind of schema this class is.

See also

UsdSchemaType

Protected Functions

inline const TfToken &_GetInstanceName() const

Returns the instance name of the API schema object belonging to a multiple-apply API schema.

The returned instance name will be empty for non-applied and single-apply API schemas.