UsdImagingDataSourcePrim Class Reference

Data source representing a basic USD prim. More...

+ Inheritance diagram for UsdImagingDataSourcePrim:

Public Member Functions

 HD_DECLARE_DATASOURCE (UsdImagingDataSourcePrim)
USDIMAGING_API TfTokenVector GetNames () override
 Returns the names for which this data source can return meaningful results. More...
USDIMAGING_API HdDataSourceBaseHandle Get (const TfToken &name) override
 Returns the data source representing name, if valid. More...
- Public Member Functions inherited from HdContainerDataSource

Static Public Member Functions

static USDIMAGING_API HdDataSourceLocatorSet Invalidate (UsdPrim const &prim, const TfToken &subprim, const TfTokenVector &properties, UsdImagingPropertyInvalidationType invalidationType)
 Returns the hydra attribute set we should invalidate if the value of the USD properties in properties change. More...
- Static Public Member Functions inherited from HdContainerDataSource
static HD_API HdDataSourceBaseHandle Get (const Handle &container, const HdDataSourceLocator &locator)
 A convenience function: given container, return the descendant identified by locator, which may be at any depth. More...

Protected Member Functions

USDIMAGING_API UsdImagingDataSourcePrim (const SdfPath &sceneIndexPath, UsdPrim usdPrim, const UsdImagingDataSourceStageGlobals &stageGlobals)
 Use to construct a new UsdImagingDataSourcePrim. More...
const SdfPath_GetSceneIndexPath () const
const UsdPrim_GetUsdPrim () const
const UsdImagingDataSourceStageGlobals_GetStageGlobals () const

Detailed Description

Data source representing a basic USD prim.

This class is meant to check for behaviors we might expect on all nodes of the scene, including interior nodes; e.g. xform, visibility. It's expected that concrete imaging types would derive from this and add imaging prim-related attributes.

Note: while every prim gets at least this datasource defined on it, this datasource tries to aggressively early out of attribute checks based on type information (IsA/HasA) or namespace-accelerated attribute checks.

Since a Usd prim can populate multiple imaging prims (e.g. /prim, /prim.a, /prim.b); and since the default prim path (/prim) is always populated; we drop inherited attributes on subprims (/prim.a), letting them inherit from /prim instead. This way we don't (e.g.) double-apply transforms.

Definition at line 486 of file dataSourcePrim.h.

Constructor & Destructor Documentation

◆ UsdImagingDataSourcePrim()

USDIMAGING_API UsdImagingDataSourcePrim ( const SdfPath sceneIndexPath,
UsdPrim  usdPrim,
const UsdImagingDataSourceStageGlobals stageGlobals 

Use to construct a new UsdImagingDataSourcePrim.

sceneIndexPath is the path of this object in the scene index. (Note: this can be different than the usd path if one usd prim inserts multiple imaging prims).

usdPrim is the USD prim object that this data source represents.

stageGlobals represents the context object for the UsdStage with which to evaluate this attribute data source.

Note: client code calls this via static New().

Member Function Documentation

◆ Get()

USDIMAGING_API HdDataSourceBaseHandle Get ( const TfToken name)

◆ GetNames()

USDIMAGING_API TfTokenVector GetNames ( )

◆ Invalidate()

static USDIMAGING_API HdDataSourceLocatorSet Invalidate ( UsdPrim const &  prim,
const TfToken subprim,
const TfTokenVector properties,
UsdImagingPropertyInvalidationType  invalidationType 

Returns the hydra attribute set we should invalidate if the value of the USD properties in properties change.

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