Loading...
Searching...
No Matches
UsdExecImagingPrimAdapter Class Referenceabstract

Base class for all exec imaging prim adapters. More...

#include <primAdapter.h>

Public Member Functions

virtual void BuildRequest (const UsdPrim &prim, UsdExecImagingRequestBuilder &requestBuilder) const =0
 Invoked by UsdExecImaging when building its exec request.
 
virtual HdContainerDataSourceHandle GetPrimData (const SdfPath &primPath, const UsdExecImagingRequestAccessorSharedPtr &requestAccessor) const =0
 Invoked by UsdExecImaging to insert computed values into the hydra scene.
 
virtual void InvalidatePrimData (const SdfPath &primPath, const UsdExecImagingValueKey &valueKey, HdDataSourceLocatorSet &invalidLocators) const =0
 Invoked by UsdExecImaging when a computed value is invalidated by authoring or by a time change.
 

Detailed Description

Base class for all exec imaging prim adapters.

Plugins implement and register classes derived from UsdExecImagingPrimAdapter to customize the imaging of prims that depend on exec-computed values.

Definition at line 32 of file primAdapter.h.

Member Function Documentation

◆ BuildRequest()

virtual void BuildRequest ( const UsdPrim & prim,
UsdExecImagingRequestBuilder & requestBuilder ) const
pure virtual

Invoked by UsdExecImaging when building its exec request.

Implementations use this method to register that the imaging of prim depends on one or more computed values. Each required computed value is registered by invoking AddValueKey on the provided requestBuilder. The value keys may be provided by prim, any of its attributes, or any other object in the scene.

◆ GetPrimData()

virtual HdContainerDataSourceHandle GetPrimData ( const SdfPath & primPath,
const UsdExecImagingRequestAccessorSharedPtr & requestAccessor ) const
pure virtual

Invoked by UsdExecImaging to insert computed values into the hydra scene.

Implementations use this method to produce data sources for the prim located at primPath. This implementation should only produce data sources for exec-computed values. The data sources produced by this method sparsely override data sources produced by the UsdImagingStageSceneIndex.

Any sampled data sources that depend on computed values should be provided from either UsdExecImagingComputedSampledDataSource or UsdExecImagingComputedTypedSampledDataSource<T>. These data sources are constructible from the provided requestAccessor.

◆ InvalidatePrimData()

virtual void InvalidatePrimData ( const SdfPath & primPath,
const UsdExecImagingValueKey & valueKey,
HdDataSourceLocatorSet & invalidLocators ) const
pure virtual

Invoked by UsdExecImaging when a computed value is invalidated by authoring or by a time change.

This method is invoked when the computed value for valueKey has changed. To be notified of a change to valueKey, it must have been added to the request during BuildRequest. primPath holds the path to the prim that was being adapted when valueKey was added to the request.

Implementations of this method add data source locators to invalidLocators corresponding to data sources that depend on the invalidated valueKey.


The documentation for this class was generated from the following file: