![]() |
|
This proxy class exposes a subset of the private Delegate API to PrimAdapters. More...
#include <indexProxy.h>
Public Member Functions | |
USDIMAGING_API void | AddDependency (SdfPath const &cachePath, UsdPrim const &usdPrim) |
A note on paths/prims: the core function of UsdImagingIndexProxy and UsdImagingDelegate is to maintain a set of mappings between USD prims and hydra prims (and a set of adapters that know how to translate USD properties to hydra buffers). | |
USDIMAGING_API void | InsertRprim (TfToken const &primType, SdfPath const &cachePath, UsdPrim const &usdPrim, UsdImagingPrimAdapterSharedPtr adapter=UsdImagingPrimAdapterSharedPtr()) |
Insert a hydra prim with the specified cache path. | |
USDIMAGING_API void | InsertSprim (TfToken const &primType, SdfPath const &cachePath, UsdPrim const &usdPrim, UsdImagingPrimAdapterSharedPtr adapter=UsdImagingPrimAdapterSharedPtr()) |
USDIMAGING_API void | InsertBprim (TfToken const &primType, SdfPath const &cachePath, UsdPrim const &usdPrim, UsdImagingPrimAdapterSharedPtr adapter=UsdImagingPrimAdapterSharedPtr()) |
USDIMAGING_API void | InsertInstancer (SdfPath const &cachePath, UsdPrim const &usdPrim, UsdImagingPrimAdapterSharedPtr adapter=UsdImagingPrimAdapterSharedPtr()) |
USDIMAGING_API void | RequestTrackVariability (SdfPath const &cachePath) |
USDIMAGING_API void | RequestUpdateForTime (SdfPath const &cachePath) |
void | RemoveRprim (SdfPath const &cachePath) |
void | RemoveSprim (TfToken const &primType, SdfPath const &cachePath) |
void | RemoveBprim (TfToken const &primType, SdfPath const &cachePath) |
void | RemoveInstancer (SdfPath const &cachePath) |
USDIMAGING_API void | MarkRprimDirty (SdfPath const &cachePath, HdDirtyBits dirtyBits) |
USDIMAGING_API void | MarkSprimDirty (SdfPath const &cachePath, HdDirtyBits dirtyBits) |
USDIMAGING_API void | MarkBprimDirty (SdfPath const &cachePath, HdDirtyBits dirtyBits) |
USDIMAGING_API void | MarkInstancerDirty (SdfPath const &cachePath, HdDirtyBits dirtyBits) |
USDIMAGING_API bool | IsRprimTypeSupported (TfToken const &typeId) const |
USDIMAGING_API bool | IsSprimTypeSupported (TfToken const &typeId) const |
USDIMAGING_API bool | IsBprimTypeSupported (TfToken const &typeId) const |
USDIMAGING_API bool | IsPopulated (SdfPath const &cachePath) const |
USDIMAGING_API void | Repopulate (SdfPath const &usdPath) |
USDIMAGING_API UsdImagingPrimAdapterSharedPtr | GetMaterialAdapter (UsdPrim const &materialPrim) |
USDIMAGING_API void | RemovePrimInfoDependency (SdfPath const &cachePath) |
Friends | |
class | UsdImagingDelegate |
This proxy class exposes a subset of the private Delegate API to PrimAdapters.
Definition at line 47 of file indexProxy.h.
A note on paths/prims: the core function of UsdImagingIndexProxy and UsdImagingDelegate is to maintain a set of mappings between USD prims and hydra prims (and a set of adapters that know how to translate USD properties to hydra buffers).
A USD prim can represent multiple hydra prims (e.g. point instancer prototypes that are referenced twice), and a hydra prim can represent multiple USD prims (e.g. a single hydra instancer prim representing multiple native instances).
There are three different prim "namespaces" that the delegate works with: "USD paths", which represent paths to USD prims; "index paths", which represent paths to hydra prims in the render index; and "cache paths", which represent paths to buffers in the value cache backing hydra prims. Cache paths and index paths are the same, except that index paths have the "delegateID" prefixed onto their path.
Index paths are only used in the interface to hydra. In IndexProxy and the adapters, the pattern is to use "cachePath" as a key to look up state for a hydra prim; and pass "usdPrim" when we additionally need to specify the related USD prim. The naming helps clarify them, and the fact that we pass a UsdPrim and not an SdfPath further ensures that we pass valid USD paths instead of passing cache paths by mistake. Adds a dependency from the given usdPrim to the given cache path. Insert* will automatically add a dependency, so this is for hydra prims that may depend on more than one usd prim (e.g. subsets, instancers)
USDIMAGING_API void InsertRprim | ( | TfToken const & | primType, |
SdfPath const & | cachePath, | ||
UsdPrim const & | usdPrim, | ||
UsdImagingPrimAdapterSharedPtr | adapter = UsdImagingPrimAdapterSharedPtr() |
||
) |
Insert a hydra prim with the specified cache path.
As mentioned above, the delegateID will be prepended before adding the prim in hydra, but cachePath will be the key into all internal usdImaging datastructures. usdPrim is the USD prim this hydra prim is representing (e.g. the UsdGeomMesh for which we are inserting a hydra mesh). If no adapter is specified, UsdImagingDelegate will choose based on Usd prim type; some clients (e.g. instancing) want to override the adapter choice but this should be used sparingly.
For Rprims and Instancers, "parentPath" is the parent instancer.
Definition at line 145 of file indexProxy.h.
|
inline |
Definition at line 153 of file indexProxy.h.
|
inline |
Definition at line 130 of file indexProxy.h.
Definition at line 137 of file indexProxy.h.
|
friend |
Definition at line 204 of file indexProxy.h.