HDK
|
#include <layerStack.h>
Friends | |
class | Pcp_LayerStackRegistry |
class | PcpCache |
bool | Pcp_NeedToRecomputeDueToAssetPathChange (const PcpLayerStackPtr &) |
Additional Inherited Members | |
Public Types inherited from TfRefBase | |
typedef void(* | UniqueChangedFuncPtr )(TfRefBase const *, bool) |
Static Public Member Functions inherited from TfRefBase | |
static TF_API void | SetUniqueChangedListener (UniqueChangedListener listener) |
Protected Member Functions inherited from TfRefBase | |
virtual TF_API | ~TfRefBase () |
Protected Member Functions inherited from TfWeakBase | |
~TfWeakBase () | |
TfRefPtr< Tf_Remnant > | _Register () const |
template<class T > | |
TfRefPtr< Tf_Remnant > | _Register (T *tempRmnt) const |
bool | _HasRemnant () const |
Represents a stack of layers that contribute opinions to composition.
Each PcpLayerStack is identified by a PcpLayerStackIdentifier. This identifier contains all of the parameters needed to construct a layer stack, such as the root layer, session layer, and path resolver context.
PcpLayerStacks are constructed and managed by a Pcp_LayerStackRegistry.
Definition at line 67 of file layerStack.h.
|
virtual |
PCP_API void PcpLayerStack::Apply | ( | const PcpLayerStackChanges & | changes, |
PcpLifeboat * | lifeboat | ||
) |
Apply the changes in changes
. This blows caches. It's up to the client to pull on those caches again as needed.
Objects that are no longer needed and would be destroyed are retained in lifeboat
and won't be destroyed until lifeboat
is itself destroyed. This gives the client control over the timing of the destruction of those objects. Clients may choose to pull on the caches before destroying lifeboat
. That may cause the caches to again retain the objects, meaning they won't be destroyed when lifeboat
is destroyed.
For example, if blowing a cache means an SdfLayer is no longer needed then lifeboat
will hold an SdfLayerRefPtr to that layer. The client can then pull on that cache, which could cause the cache to hold an SdfLayerRefPtr to the layer again. If so then destroying changes
will not destroy the layer. In any case, we don't destroy the layer and then read it again. However, if the client destroys lifeboat
before pulling on the cache then we would destroy the layer then read it again.
PCP_API PcpMapExpression PcpLayerStack::GetExpressionForRelocatesAtPath | ( | const SdfPath & | path | ) |
Return a PcpMapExpression representing the relocations that affect namespace at and below the given path. The value of this expression will continue to track the effective relocations if they are changed later.
|
inline |
Return the set of expression variables used during the computation of this layer stack. For example, this may include the variables used in expression variable expressions in sublayer asset paths.
Definition at line 136 of file layerStack.h.
|
inline |
Return the composed expression variables for this layer stack.
Definition at line 129 of file layerStack.h.
PCP_API const PcpLayerStackIdentifier& PcpLayerStack::GetIdentifier | ( | ) | const |
Returns the identifier for this layer stack.
PCP_API const SdfRelocatesMap& PcpLayerStack::GetIncrementalRelocatesSourceToTarget | ( | ) | const |
Returns incremental relocation source-to-target mapping for this layer stack.
This map contains the individual relocation entries found across all layers in this layer stack; it does not combine ancestral entries with descendant entries. For instance, if this layer stack contains relocations { /A: /B } and { /A/C: /A/D }, this map will contain { /A: /B } and { /A/C: /A/D }.
PCP_API const SdfRelocatesMap& PcpLayerStack::GetIncrementalRelocatesTargetToSource | ( | ) | const |
Returns incremental relocation target-to-source mapping for this layer stack.
See GetIncrementalRelocatesTargetToSource for more details.
PCP_API const SdfLayerOffset* PcpLayerStack::GetLayerOffsetForLayer | ( | const SdfLayerHandle & | ) | const |
Returns the layer offset for the given layer, or NULL if the layer can't be found or is the identity.
PCP_API const SdfLayerOffset* PcpLayerStack::GetLayerOffsetForLayer | ( | const SdfLayerRefPtr & | ) | const |
Return the layer offset for the given layer, or NULL if the layer can't be found or is the identity.
PCP_API const SdfLayerOffset* PcpLayerStack::GetLayerOffsetForLayer | ( | size_t | layerIdx | ) | const |
Returns the layer offset for the layer at the given index in this layer stack. Returns NULL if the offset is the identity.
PCP_API const SdfLayerRefPtrVector& PcpLayerStack::GetLayers | ( | ) | const |
Returns the layers in this layer stack in strong-to-weak order. Note that this is only the local layer stack – it does not include any layers brought in by references inside prims.
PCP_API const SdfLayerTreeHandle& PcpLayerStack::GetLayerTree | ( | ) | const |
Returns the layer tree representing the structure of this layer stack.
|
inline |
Return the list of errors local to this layer stack.
Definition at line 117 of file layerStack.h.
PCP_API const std::set<std::string>& PcpLayerStack::GetMutedLayers | ( | ) | const |
Returns the set of layers that were muted in this layer stack.
PCP_API const SdfPathVector& PcpLayerStack::GetPathsToPrimsWithRelocates | ( | ) | const |
Returns a list of paths to all prims across all layers in this layer stack that contained relocates.
PCP_API const SdfRelocatesMap& PcpLayerStack::GetRelocatesSourceToTarget | ( | ) | const |
Returns relocation source-to-target mapping for this layer stack.
This map combines the individual relocation entries found across all layers in this layer stack; multiple entries that affect a single prim will be combined into a single entry. For instance, if this layer stack contains relocations { /A: /B } and { /A/C: /A/D }, this map will contain { /A: /B } and { /B/C: /B/D }. This allows consumers to go from unrelocated namespace to relocated namespace in a single step.
PCP_API const SdfRelocatesMap& PcpLayerStack::GetRelocatesTargetToSource | ( | ) | const |
Returns relocation target-to-source mapping for this layer stack.
See GetRelocatesSourceToTarget for more details.
PCP_API SdfLayerHandleVector PcpLayerStack::GetSessionLayers | ( | ) | const |
Returns only the session layers in the layer stack in strong-to-weak order.
|
inline |
Return the time codes per second value of the layer stack. This is usually the same as the computed time codes per second of the root layer but may be computed from the session layer when its present.
Definition at line 142 of file layerStack.h.
PCP_API bool PcpLayerStack::HasLayer | ( | const SdfLayerHandle & | layer | ) | const |
Returns true if this layer stack contains the given layer, false otherwise.
PCP_API bool PcpLayerStack::HasLayer | ( | const SdfLayerRefPtr & | layer | ) | const |
|
friend |
Definition at line 216 of file layerStack.h.
|
friend |
Definition at line 218 of file layerStack.h.