24 #ifndef PXR_USD_IMAGING_USD_IMAGING_RESOLVED_ATTRIBUTE_CACHE_H 25 #define PXR_USD_IMAGING_USD_IMAGING_RESOLVED_ATTRIBUTE_CACHE_H 30 #include "pxr/usdImaging/usdImaging/api.h" 32 #include "pxr/usd/usd/primRange.h" 34 #include "pxr/usd/sdf/path.h" 38 #include <boost/functional/hash.hpp> 39 #include <tbb/concurrent_unordered_map.h> 42 PXR_NAMESPACE_OPEN_SCOPE
66 template<
typename Strategy,
typename ImplData=
bool>
67 class UsdImaging_ResolvedAttributeCache
71 typedef tbb::concurrent_unordered_map<
UsdPrim,
73 boost::hash<UsdPrim> > _CacheMap;
75 typedef typename Strategy::value_type value_type;
76 typedef typename Strategy::query_type query_type;
78 typedef TfHashMap<UsdPrim, value_type, boost::hash<UsdPrim> >
82 explicit UsdImaging_ResolvedAttributeCache(
84 ImplData *implData=
nullptr,
85 const ValueOverridesMap valueOverrides=ValueOverridesMap())
87 , _rootPath(
SdfPath::AbsoluteRootPath())
88 , _cacheVersion(_GetInitialCacheVersion())
89 , _valueOverrides(valueOverrides)
95 UsdImaging_ResolvedAttributeCache()
97 , _rootPath(
SdfPath::AbsoluteRootPath())
102 ~UsdImaging_ResolvedAttributeCache()
110 value_type GetValue(
const UsdPrim& prim)
const 115 "which is not within the specified root: %s",
117 _rootPath.GetString().c_str());
118 return Strategy::MakeDefault();
121 return *_GetValue(prim);
128 GetQuery(
const UsdPrim& prim)
const {
129 return &_GetCacheEntryForPrim(prim)->query;
135 _cacheVersion = _GetInitialCacheVersion();
145 if (Strategy::ValueMightBeTimeVarying()) {
167 void SetRootPath(
const SdfPath& rootPath) {
174 if (rootPath == _rootPath)
178 _rootPath = rootPath;
183 const SdfPath & GetRootPath()
const {
return _rootPath; }
195 void UpdateValueOverrides(
const ValueOverridesMap &valueOverrides,
196 const std::vector<UsdPrim> &overridesToRemove,
197 std::vector<SdfPath> *dirtySubtreeRoots)
201 if (valueOverrides.empty() && overridesToRemove.empty())
204 ValueOverridesMap valueOverridesToProcess;
205 SdfPathVector processedOverridePaths;
207 const UsdPrim &prim = it->first;
208 const value_type &value = it->second;
212 if (*_GetValue(prim) == value)
215 valueOverridesToProcess[prim] = value;
219 const UsdPrim &prim = it->first;
220 const value_type &value = it->second;
227 bool isDescendantOfProcessedOverride =
false;
228 for (
const SdfPath &processedPath : processedOverridePaths) {
230 isDescendantOfProcessedOverride =
true;
237 if (!isDescendantOfProcessedOverride) {
239 if (_Entry* entry = _GetCacheEntryForPrim(descendant)) {
240 entry->version = _GetInvalidVersion();
243 processedOverridePaths.push_back(prim.
GetPath());
244 dirtySubtreeRoots->push_back(prim.
GetPath());
248 _valueOverrides[prim] = value;
251 for (
const UsdPrim &prim : overridesToRemove) {
254 size_t numErased = _valueOverrides.erase(prim);
257 if (numErased == 0) {
261 bool isDescendantOfProcessedOverride =
false;
262 for (
const SdfPath &processedPath : processedOverridePaths) {
264 isDescendantOfProcessedOverride =
true;
271 if (!isDescendantOfProcessedOverride) {
273 if (_Entry* entry = _GetCacheEntryForPrim(descendant)) {
274 entry->version = _GetInvalidVersion();
277 dirtySubtreeRoots->push_back(prim.
GetPath());
278 processedOverridePaths.push_back(prim.
GetPath());
289 : value(Strategy::MakeDefault())
290 , version(_GetInitialEntryVersion())
293 _Entry(
const query_type & query_,
294 const value_type& value_,
303 tbb::atomic<unsigned> version;
307 unsigned _GetValidVersion()
const {
return _cacheVersion + 1; }
310 unsigned _GetInvalidVersion()
const {
return _cacheVersion - 1; }
313 static unsigned _GetInitialCacheVersion() {
return 1; }
314 static unsigned _GetInitialEntryVersion() {
315 return _GetInitialCacheVersion()-1;
320 value_type
const* _GetValue(
const UsdPrim& prim)
const;
323 _Entry* _GetCacheEntryForPrim(
const UsdPrim &prim)
const;
328 void _SetCacheEntryForPrim(
const UsdPrim &prim,
329 value_type
const& value,
330 _Entry* entry)
const;
335 mutable _CacheMap _cache;
343 tbb::atomic<unsigned> _cacheVersion;
346 ValueOverridesMap _valueOverrides;
352 template<
typename Strategy,
typename ImplData>
354 UsdImaging_ResolvedAttributeCache<Strategy,ImplData>::_SetCacheEntryForPrim(
356 value_type
const& value,
360 unsigned v = entry->version;
361 if (v < _cacheVersion
362 && entry->version.compare_and_swap(_cacheVersion, v) == v)
364 entry->value = value;
365 entry->version = _GetValidVersion();
367 while (entry->version != _GetValidVersion()) {
377 template<
typename Strategy,
typename ImplData>
378 typename UsdImaging_ResolvedAttributeCache<Strategy, ImplData>::_Entry*
379 UsdImaging_ResolvedAttributeCache<Strategy, ImplData>::_GetCacheEntryForPrim(
382 typename _CacheMap::const_iterator it = _cache.find(prim);
383 if (it != _cache.end()) {
388 e.query = Strategy::MakeQuery(prim, _implData);
389 e.value = Strategy::MakeDefault();
390 e.version = _GetInvalidVersion();
391 return &(_cache.insert(
392 typename _CacheMap::value_type(prim, e)).first->second);
395 template<
typename Strategy,
typename ImplData>
396 typename UsdImaging_ResolvedAttributeCache<Strategy, ImplData>::value_type
const*
397 UsdImaging_ResolvedAttributeCache<Strategy, ImplData>::_GetValue(
400 static value_type
const default_ = Strategy::MakeDefault();
406 _Entry* entry = _GetCacheEntryForPrim(prim);
407 if (entry->version == _GetValidVersion()) {
409 return &entry->value;
419 typename ValueOverridesMap::const_iterator it =
420 _valueOverrides.find(prim);
421 if (it != _valueOverrides.end()) {
422 _SetCacheEntryForPrim(prim, it->second, entry);
424 _SetCacheEntryForPrim(prim,
425 Strategy::Compute(
this, prim, &entry->query),
428 return &entry->value;
431 PXR_NAMESPACE_CLOSE_SCOPE
440 PXR_NAMESPACE_OPEN_SCOPE
442 struct UsdImaging_XfStrategy;
443 typedef UsdImaging_ResolvedAttributeCache<UsdImaging_XfStrategy> UsdImaging_XformCache;
445 struct UsdImaging_XfStrategy {
450 bool ValueMightBeTimeVarying() {
return true; }
452 value_type MakeDefault() {
return GfMatrix4d(1); }
455 query_type MakeQuery(
UsdPrim const& prim,
bool *) {
457 return query_type(xf);
464 Compute(UsdImaging_XformCache
const* owner,
466 query_type
const* query)
468 value_type xform = MakeDefault();
471 query->GetLocalTransformation(&xform, owner->GetTime());
473 return !query->GetResetXformStack()
474 ? (xform * (*owner->_GetValue(prim.
GetParent())))
482 ComputeTransform(
UsdPrim const& prim,
485 const TfHashMap<SdfPath, GfMatrix4d, SdfPath::Hash> &ctmOverrides)
491 while (p && p.
GetPath() != rootPath) {
492 const auto &overIt = ctmOverrides.find(p.
GetPath());
494 if (overIt != ctmOverrides.end()) {
495 ctm *= overIt->second;
498 if (xf.GetLocalTransformation(&localXf, &reset, time))
509 PXR_NAMESPACE_CLOSE_SCOPE
517 #include "pxr/usdImaging/usdImaging/debugCodes.h" 519 PXR_NAMESPACE_OPEN_SCOPE
521 struct UsdImaging_VisStrategy;
522 using UsdImaging_VisCache =
523 UsdImaging_ResolvedAttributeCache<UsdImaging_VisStrategy>;
528 struct UsdImaging_VisStrategy {
533 bool ValueMightBeTimeVarying() {
return true; }
536 value_type MakeDefault() {
return UsdGeomTokens->inherited; }
539 query_type MakeQuery(
UsdPrim const& prim,
bool *)
542 return query_type(xf.GetVisibilityAttr());
549 Compute(UsdImaging_VisCache
const* owner,
551 query_type
const* query)
553 value_type v = *owner->_GetValue(prim.
GetParent());
563 query->Get(&v, owner->GetTime());
580 struct UsdImaging_PurposeStrategy;
581 typedef UsdImaging_ResolvedAttributeCache<UsdImaging_PurposeStrategy>
582 UsdImaging_PurposeCache;
584 struct UsdImaging_PurposeStrategy {
592 value_type MakeDefault() {
598 query_type MakeQuery(
UsdPrim const& prim,
bool *) {
600 return query_type(im.GetPurposeAttr());
607 Compute(UsdImaging_PurposeCache
const* owner,
609 query_type
const* query)
615 return *(owner->_GetValue(prim.
GetParent()));
619 if (query->HasAuthoredValue()) {
621 query->Get(&info.purpose);
622 info.isInheritable =
true;
629 const value_type *v = owner->_GetValue(prim.
GetParent());
630 if (v->isInheritable) {
637 query->Get(&info.purpose);
643 ComputePurposeInfo(
UsdPrim const& prim)
649 PXR_NAMESPACE_CLOSE_SCOPE
658 PXR_NAMESPACE_OPEN_SCOPE
660 struct UsdImaging_MaterialBindingImplData {
663 UsdImaging_MaterialBindingImplData(
const TfToken &materialPurpose):
664 _materialPurpose(materialPurpose)
669 ~UsdImaging_MaterialBindingImplData() {
674 const TfToken &GetMaterialPurpose()
const {
675 return _materialPurpose;
681 {
return _bindingsCache; }
686 {
return _collQueryCache; }
692 const TfToken _materialPurpose;
697 struct UsdImaging_MaterialStrategy;
698 typedef UsdImaging_ResolvedAttributeCache<UsdImaging_MaterialStrategy,
699 UsdImaging_MaterialBindingImplData>
700 UsdImaging_MaterialBindingCache;
702 struct UsdImaging_MaterialStrategy {
713 using ImplData = UsdImaging_MaterialBindingImplData;
716 bool ValueMightBeTimeVarying() {
return false; }
718 value_type MakeDefault() {
return SdfPath(); }
721 query_type MakeQuery(
728 &implData->GetBindingsCache(),
729 &implData->GetCollectionQueryCache(),
730 implData->GetMaterialPurpose(),
745 Compute(UsdImaging_MaterialBindingCache
const* owner,
747 query_type
const* query)
749 TF_DEBUG(USDIMAGING_SHADERS).Msg(
"Looking for \"preview\" material " 764 ComputeMaterialPath(
UsdPrim const& prim, ImplData *implData) {
769 &implData->GetBindingsCache(),
770 &implData->GetCollectionQueryCache(),
771 implData->GetMaterialPurpose(),
784 PXR_NAMESPACE_CLOSE_SCOPE
792 PXR_NAMESPACE_OPEN_SCOPE
794 struct UsdImaging_DrawModeStrategy;
795 typedef UsdImaging_ResolvedAttributeCache<UsdImaging_DrawModeStrategy>
796 UsdImaging_DrawModeCache;
798 struct UsdImaging_DrawModeStrategy
804 bool ValueMightBeTimeVarying() {
return false; }
809 query_type MakeQuery(
UsdPrim const& prim,
bool *) {
811 return query_type(modelApi.GetModelDrawModeAttr());
818 Compute(UsdImaging_DrawModeCache
const* owner,
820 query_type
const* query)
842 ComputeDrawMode(
UsdPrim const& prim)
848 PXR_NAMESPACE_CLOSE_SCOPE
856 PXR_NAMESPACE_OPEN_SCOPE
858 struct UsdImaging_PointInstancerIndicesStrategy;
859 typedef UsdImaging_ResolvedAttributeCache<UsdImaging_PointInstancerIndicesStrategy>
860 UsdImaging_PointInstancerIndicesCache;
862 struct UsdImaging_PointInstancerIndicesStrategy
867 typedef int query_type;
880 bool ValueMightBeTimeVarying() {
return true; }
882 value_type MakeDefault() {
return value_type(); }
885 query_type MakeQuery(
UsdPrim const& prim,
bool *) {
891 Compute(UsdImaging_PointInstancerIndicesCache
const* owner,
893 query_type
const* query)
895 return ComputePerPrototypeIndices(prim, owner->GetTime());
905 VtIntArray protoIndices;
906 if (!pi.GetProtoIndicesAttr().Get(&protoIndices, time)) {
907 TF_WARN(
"Failed to read point instancer protoIndices");
911 std::vector<bool> mask = pi.ComputeMaskAtTime(time);
913 for (
size_t instanceId = 0; instanceId < protoIndices.size(); ++instanceId) {
914 size_t protoIndex = protoIndices[instanceId];
916 if (protoIndex >= v.size()) {
917 v.resize(protoIndex + 1);
920 if (mask.size() == 0 || mask[instanceId]) {
921 v[protoIndex].push_back(instanceId);
929 PXR_NAMESPACE_CLOSE_SCOPE
936 #include "pxr/imaging/hd/coordSys.h" 938 PXR_NAMESPACE_OPEN_SCOPE
940 struct UsdImaging_CoordSysBindingStrategy;
942 typedef UsdImaging_ResolvedAttributeCache<UsdImaging_CoordSysBindingStrategy>
943 UsdImaging_CoordSysBindingCache;
945 struct UsdImaging_CoordSysBindingStrategy
947 typedef std::vector<UsdShadeCoordSysAPI::Binding> UsdBindingVec;
948 typedef std::shared_ptr<UsdBindingVec> UsdBindingVecPtr;
949 typedef std::shared_ptr<SdfPathVector> IdVecPtr;
953 UsdBindingVecPtr usdBindingVecPtr;
955 typedef int query_type;
958 bool ValueMightBeTimeVarying() {
return false; }
961 value_type MakeDefault() {
966 query_type MakeQuery(
UsdPrim const& prim,
bool *) {
972 Compute(UsdImaging_CoordSysBindingCache
const* owner,
974 query_type
const* query)
980 v = *owner->_GetValue(parentPrim);
983 auto _IterateLocalBindings = [&prim](
const UsdBindingVec &localBindings,
984 SdfPathVector &hdIds, UsdBindingVec &usdBindings) {
986 if (!prim.
GetStage()->GetPrimAtPath(
987 binding.coordSysPrimPath).IsValid()) {
990 TF_WARN(
"UsdImaging: Ignore coordinate system binding to " 991 "non-existent prim <%s>\n",
992 binding.coordSysPrimPath.GetText());
996 for (
size_t id = 0, n = hdIds.size();
id < n; ++id) {
997 if (usdBindings[
id].name == binding.name) {
999 usdBindings[id] = binding;
1000 hdIds[id] = binding.bindingRelPath;
1007 usdBindings.push_back(binding);
1008 hdIds.push_back(binding.bindingRelPath);
1021 if (hasLocalBindings && !localBindings.empty()) {
1022 SdfPathVector hdIds;
1023 UsdBindingVec usdBindings;
1025 hdIds = *v.idVecPtr;
1027 if (v.usdBindingVecPtr) {
1028 usdBindings = *v.usdBindingVecPtr;
1030 _IterateLocalBindings(localBindings, hdIds, usdBindings);
1031 v.idVecPtr.reset(
new SdfPathVector(std::move(hdIds)));
1032 v.usdBindingVecPtr.reset(
new UsdBindingVec(std::move(usdBindings)));
1039 PXR_NAMESPACE_CLOSE_SCOPE
1047 PXR_NAMESPACE_OPEN_SCOPE
1049 struct UsdImaging_NonlinearSampleCountStrategy;
1050 typedef UsdImaging_ResolvedAttributeCache<
1051 UsdImaging_NonlinearSampleCountStrategy>
1052 UsdImaging_NonlinearSampleCountCache;
1054 struct UsdImaging_NonlinearSampleCountStrategy
1056 typedef int value_type;
1061 static constexpr value_type invalidValue = -1;
1064 bool ValueMightBeTimeVarying() {
return true; }
1067 value_type MakeDefault() {
1068 return invalidValue;
1072 query_type MakeQuery(
UsdPrim const& prim,
bool *) {
1074 return query_type(motionAPI.GetNonlinearSampleCountAttr());
1076 return query_type();
1081 Compute(UsdImaging_NonlinearSampleCountCache
const* owner,
1083 query_type
const* query)
1085 if (query->HasAuthoredValue()) {
1087 if (query->Get(&value, owner->GetTime())) {
1092 return *owner->_GetValue(prim.
GetParent());
1103 PXR_NAMESPACE_CLOSE_SCOPE
1111 PXR_NAMESPACE_OPEN_SCOPE
1113 struct UsdImaging_BlurScaleStrategy;
1114 typedef UsdImaging_ResolvedAttributeCache<UsdImaging_BlurScaleStrategy>
1115 UsdImaging_BlurScaleCache;
1117 struct UsdImaging_BlurScaleStrategy
1128 static const value_type invalidValue;
1131 bool ValueMightBeTimeVarying() {
return true; }
1134 value_type MakeDefault() {
1135 return invalidValue;
1139 query_type MakeQuery(
UsdPrim const& prim,
bool *) {
1141 return query_type(motionAPI.GetMotionBlurScaleAttr());
1143 return query_type();
1148 Compute(UsdImaging_BlurScaleCache
const* owner,
1150 query_type
const* query)
1152 if (query->HasAuthoredValue()) {
1154 if (query->Get(&value, owner->GetTime())) {
1155 return { value,
true };
1159 return *owner->_GetValue(prim.
GetParent());
1170 PXR_NAMESPACE_CLOSE_SCOPE
1178 PXR_NAMESPACE_OPEN_SCOPE
1180 struct UsdImaging_InheritedPrimvarStrategy;
1181 typedef UsdImaging_ResolvedAttributeCache<UsdImaging_InheritedPrimvarStrategy>
1182 UsdImaging_InheritedPrimvarCache;
1184 struct UsdImaging_InheritedPrimvarStrategy
1186 struct PrimvarRecord {
1187 std::vector<UsdGeomPrimvar> primvars;
1190 typedef std::shared_ptr<PrimvarRecord> value_type;
1196 bool ValueMightBeTimeVarying() {
return false; }
1199 value_type MakeDefault() {
1200 return value_type();
1204 query_type MakeQuery(
UsdPrim const& prim,
bool *) {
1209 value_type Compute(UsdImaging_InheritedPrimvarCache
const* owner,
1211 query_type
const* query)
1217 v = *owner->_GetValue(parentPrim);
1220 std::vector<UsdGeomPrimvar> primvars =
1221 query->FindIncrementallyInheritablePrimvars(
1222 v ? v->primvars : std::vector<UsdGeomPrimvar>());
1223 if (!primvars.empty()) {
1224 v = std::make_shared<PrimvarRecord>();
1225 v->primvars = std::move(primvars);
1226 v->variable =
false;
1239 PXR_NAMESPACE_CLOSE_SCOPE
UsdShadeCoordSysAPI provides a way to designate, name, and discover coordinate systems.
UsdGeomModelAPI extends the generic UsdModelAPI schema with geometry specific concepts such as cached...
USD_API UsdStageWeakPtr GetStage() const
Return the stage that owns the object, and to whose state and lifetime this object's validity is tied...
Object for efficiently making repeated queries for attribute values.
#define TF_WARN(...)
Issue a warning, but continue execution.
tbb::concurrent_unordered_map< SdfPath, std::unique_ptr< UsdCollectionAPI::MembershipQuery >, SdfPath::Hash > CollectionQueryCache
An unordered list of collection paths mapped to the associated collection's MembershipQuery object.
#define TF_CODING_ERROR(fmt, args)
Issue an internal programming error, but continue execution.
SDF_API const char * GetText() const
Returns the string representation of this path as a c string.
SDF_API bool HasPrefix(const SdfPath &prefix) const
Return true if both this path and prefix are not the empty path and this path has prefix as a prefix.
bool IsInPrototype() const
Return true if this prim is a prototype prim or a descendant of a prototype prim, false otherwise.
tbb::concurrent_unordered_map< SdfPath, std::unique_ptr< BindingsAtPrim >, SdfPath::Hash > BindingsCache
An unordered list of prim-paths mapped to the corresponding set of bindings at the associated prim.
A coordinate system binding.
UsdShadeMaterialBindingAPI is an API schema that provides an interface for binding materials to prims...
UsdGeomPrimvarsAPI encodes geometric "primitive variables", as UsdGeomPrimvar, which interpolate acro...
USDGEOM_API PurposeInfo ComputePurposeInfo() const
Calculate the effective purpose information about this prim which includes final computed purpose val...
USDGEOM_API int ComputeNonlinearSampleCount(UsdTimeCode time=UsdTimeCode::Default()) const
Compute the inherited value of nonlinearSampleCount at time, i.e.
Token for efficient comparison, assignment, and hashing of known strings.
#define TF_FOR_ALL(iter, c)
Macro for iterating over a container.
Stores a 4x4 matrix of double elements.
Represent a time value, which may be either numeric, holding a double value, or a sentinel value UsdT...
USDGEOM_API TfStaticData< UsdGeomTokensType > UsdGeomTokens
A global variable with static, efficient TfTokens for use in all public USD API.
UsdPrim GetParent() const
Return this prim's parent prim.
Value type containing information about a prim's computed effective purpose as well as storing whethe...
#define TRACE_FUNCTION()
Records a timestamp when constructed and a timespan event when destructed, using the name of the func...
SdfPath GetPath() const
Shorthand for GetPrim()->GetPath().
USDGEOM_API TfToken ComputeVisibility(UsdTimeCode const &time=UsdTimeCode::Default()) const
Calculate the effective visibility of this prim, as defined by its most ancestral authored "invisible...
UsdPrim is the sole persistent scenegraph object on a UsdStage, and is the embodiment of a "Prim" as ...
USDSHADE_API bool HasLocalBindings() const
Returns true if the prim has local coordinate system relationship exists.
Represents an arbitrary dimensional rectangular container class.
A path value used to locate objects in layers or scenegraphs.
SDF_API const std::string & GetString() const
Return the string representation of this path as a std::string.
#define TF_DEBUG(enumVal)
Evaluate and print debugging message msg if enumVal is enabled for debugging.
UsdGeomMotionAPI encodes data that can live on any prim that may affect computations involving:
A UsdRelationship creates dependencies between scenegraph objects by allowing a prim to target other ...
SDF_API bool IsAbsolutePath() const
Returns whether the path is absolute.
An forward-iterable range that traverses a subtree of prims rooted at a given prim in depth-first ord...
USDSHADE_API UsdShadeMaterial ComputeBoundMaterial(BindingsCache *bindingsCache, CollectionQueryCache *collectionQueryCache, const TfToken &materialPurpose=UsdShadeTokens->allPurpose, UsdRelationship *bindingRel=nullptr) const
Computes the resolved bound material for this prim, for the given material purpose.
USDGEOM_API TfToken ComputeModelDrawMode(const TfToken &parentDrawMode=TfToken()) const
Calculate the effective model:drawMode of this prim.
bool IsPrototype() const
Return true if this prim is an instancing prototype prim, false otherwise.
A Material provides a container into which multiple "render targets" can add data that defines a "sha...
USDSHADE_API std::vector< Binding > GetLocalBindings() const
Get the list of coordinate system bindings local to this prim.
Encodes vectorized instancing of multiple, potentially animated, prototypes (object/instance masters)...
Schema wrapper for UsdAttribute for authoring and introspecting attributes that are primvars.
void WorkSwapDestroyAsync(T &obj)
Swap obj with a default-constructed T instance, return and arrange for the swapped-out instance to be...
bool IsEmpty() const noexcept
Returns true if this is the empty path (SdfPath::EmptyPath()).
static USDSHADE_API const SdfPath GetResolvedTargetPathFromBindingRel(const UsdRelationship &bindingRel)
returns the path of the resolved target identified by bindingRel.
Base class for all prims that may require rendering or visualization of some sort.
TfToken class for efficient string referencing and hashing, plus conversions to and from stl string c...
SdfPath GetPath() const
Return the complete scene path to this object on its UsdStage, which may (UsdPrim) or may not (all ot...
USDGEOM_API bool ValueMightBeTimeVarying() const
Return true if it is possible, but not certain, that this primvar's value changes over time,...
USDGEOM_API float ComputeMotionBlurScale(UsdTimeCode time=UsdTimeCode::Default()) const
Compute the inherited value of motion:blurScale at time, i.e.