HDK
|
#include "pxr/pxr.h"
#include "pxr/usd/usdShade/api.h"
#include "pxr/base/gf/vec3f.h"
#include "pxr/base/vt/array.h"
#include "pxr/base/tf/type.h"
Go to the source code of this file.
Classes | |
class | UsdShadeConnectableAPIBehavior |
Functions | |
template<class PrimType , class BehaviorType = UsdShadeConnectableAPIBehavior> | |
void | UsdShadeRegisterConnectableAPIBehavior () |
USDSHADE_API void | UsdShadeRegisterConnectableAPIBehavior (const TfType &connectablePrimType, const std::shared_ptr< UsdShadeConnectableAPIBehavior > &behavior) |
|
inline |
Registers behavior
to define connectability of attributes for PrimType
.
Plugins should call this function in a TF_REGISTRY_FUNCTION. For example:
Plugins must also note that UsdShadeConnectableAPI behavior is implemented for a prim type in that type's schema definnition. For example:
This allows the plugin system to discover this behavior dynamically and load the plugin if needed.
In addition to Typed schemas, single apply API schemas can also include providesUsdShadeConnectableAPIBehavior in their extraPlugInfo and hence impart connectableAPIBehavior to the prim definition in which they are participating. Additionally a schema can include metadata in their extraPlugInfo fields to override isContainer and requiresEncapsulation properties by specifying bool values for isUsdShadeContainer and requiresUsdShadeEncapsulation. This can be especially useful for codeless_schema that cannot provide a C++ derivation of UsdShadeConnectableAPIBehavior.
UsdShadeConnectableAPIBehavior_ResolutionOrder defines the resolution order when multiple types and apiSchemas provide a UsdShadeConnectableAPIBehavior.
Definition at line 208 of file connectableAPIBehavior.h.
USDSHADE_API void UsdShadeRegisterConnectableAPIBehavior | ( | const TfType & | connectablePrimType, |
const std::shared_ptr< UsdShadeConnectableAPIBehavior > & | behavior | ||
) |
Registers behavior
to define connectability of attributes for PrimType
.