HDK
|
#include <node.h>
Classes | |
struct | Hash |
Hash functor. More... | |
Public Types | |
typedef PcpNodeRef_ChildrenIterator | child_const_iterator |
typedef PcpNodeRef_ChildrenReverseIterator | child_const_reverse_iterator |
typedef std::pair < child_const_iterator, child_const_iterator > | child_const_range |
Public Member Functions | |
PcpNodeRef () | |
Pcp_CompressedSdSite | GetCompressedSdSite (size_t layerIndex) const |
Arc information | |
Information pertaining to the arcs connecting this node to its parent and child nodes. | |
PCP_API PcpArcType | GetArcType () const |
Returns the type of arc connecting this node to its parent node. More... | |
PCP_API PcpNodeRef | GetParentNode () const |
PCP_API child_const_range | GetChildrenRange () const |
PCP_API PcpNodeRef | InsertChild (const PcpLayerStackSite &site, const PcpArc &arc, PcpErrorBasePtr *error) |
PCP_API PcpNodeRef | InsertChildSubgraph (const PcpPrimIndex_GraphRefPtr &subgraph, const PcpArc &arc, PcpErrorBasePtr *error) |
PCP_API PcpNodeRef | GetOriginNode () const |
PCP_API PcpNodeRef | GetOriginRootNode () const |
PCP_API PcpNodeRef | GetRootNode () const |
Walk up to the root node of this expression. More... | |
PCP_API const PcpMapExpression & | GetMapToParent () const |
PCP_API const PcpMapExpression & | GetMapToRoot () const |
PCP_API int | GetSiblingNumAtOrigin () const |
PCP_API int | GetNamespaceDepth () const |
PCP_API int | GetDepthBelowIntroduction () const |
PCP_API SdfPath | GetPathAtIntroduction () const |
Returns the path for this node's site when it was introduced. More... | |
PCP_API SdfPath | GetIntroPath () const |
Node information | |
Information pertaining specifically to this node and the opinions that it may or may not provide. | |
PCP_API PcpLayerStackSite | GetSite () const |
Get the site this node represents. More... | |
PCP_API const SdfPath & | GetPath () const |
Returns the path for the site this node represents. More... | |
PCP_API const PcpLayerStackRefPtr & | GetLayerStack () const |
Returns the layer stack for the site this node represents. More... | |
PCP_API bool | IsRootNode () const |
Returns true if this node is the root node of the prim index graph. More... | |
PCP_API void | SetIsDueToAncestor (bool isDueToAncestor) |
PCP_API bool | IsDueToAncestor () const |
Get the site this node represents. More... | |
PCP_API void | SetHasSymmetry (bool hasSymmetry) |
PCP_API bool | HasSymmetry () const |
Get the site this node represents. More... | |
PCP_API void | SetPermission (SdfPermission perm) |
PCP_API SdfPermission | GetPermission () const |
Get the site this node represents. More... | |
PCP_API void | SetInert (bool inert) |
PCP_API bool | IsInert () const |
Get the site this node represents. More... | |
PCP_API void | SetCulled (bool culled) |
PCP_API bool | IsCulled () const |
Get the site this node represents. More... | |
PCP_API void | SetRestricted (bool restricted) |
PCP_API bool | IsRestricted () const |
Get the site this node represents. More... | |
PCP_API bool | CanContributeSpecs () const |
PCP_API size_t | GetSpecContributionRestrictedDepth () const |
PCP_API void | SetSpecContributionRestrictedDepth (size_t depth) |
PCP_API void | SetHasSpecs (bool hasSpecs) |
PCP_API bool | HasSpecs () const |
Get the site this node represents. More... | |
Operators / Miscellaneous | |
typedef size_t PcpNodeRef::* | UnspecifiedBoolType |
Returns true if this is a valid node reference, false otherwise. More... | |
operator UnspecifiedBoolType () const | |
Returns true if this is a valid node reference, false otherwise. More... | |
bool | operator== (const PcpNodeRef &rhs) const |
Returns true if this references the same node as rhs . More... | |
bool | operator!= (const PcpNodeRef &rhs) const |
PCP_API bool | operator< (const PcpNodeRef &rhs) const |
bool | operator<= (const PcpNodeRef &rhs) const |
bool | operator> (const PcpNodeRef &rhs) const |
bool | operator>= (const PcpNodeRef &rhs) const |
PcpPrimIndex_Graph * | GetOwningGraph () const |
Returns the graph that this node belongs to. More... | |
PCP_API void * | GetUniqueIdentifier () const |
Returns a value that uniquely identifies this node. More... | |
PcpNode represents a node in an expression tree for compositing scene description.
A node represents the opinions from a particular site. In addition, it may have child nodes, representing nested expressions that are composited over/under this node.
Child nodes are stored and composited in strength order.
Each node holds information about the arc to its parent. This captures both the relative strength of the sub-expression as well as any value-mapping needed, such as to rename opinions from a model to use in a particular instance.
typedef std::pair<child_const_iterator, child_const_iterator> PcpNodeRef::child_const_range |
typedef size_t PcpNodeRef::* PcpNodeRef::UnspecifiedBoolType |
PCP_API bool PcpNodeRef::CanContributeSpecs | ( | ) | const |
Returns true if this node is allowed to contribute opinions for composition, false otherwise.
PCP_API PcpArcType PcpNodeRef::GetArcType | ( | ) | const |
Returns the type of arc connecting this node to its parent node.
PCP_API child_const_range PcpNodeRef::GetChildrenRange | ( | ) | const |
Returns an iterator range over the children nodes in strongest to weakest order.
|
inline |
Return the number of levels of namespace this node's site is below the level at which it was introduced by an arc.
Get the path that introduced this node. Specifically, this is the path the parent node had at the level of namespace where this node was added as a child. For a root node, this returns the absolute root path. See also GetDepthBelowIntroduction().
PCP_API const PcpLayerStackRefPtr& PcpNodeRef::GetLayerStack | ( | ) | const |
Returns the layer stack for the site this node represents.
PCP_API const PcpMapExpression& PcpNodeRef::GetMapToParent | ( | ) | const |
Returns mapping function used to translate paths and values from this node to its parent node.
PCP_API const PcpMapExpression& PcpNodeRef::GetMapToRoot | ( | ) | const |
Returns mapping function used to translate paths and values from this node directly to the root node.
Returns the absolute namespace depth of the node that introduced this node. Note that this does not count any variant selections.
PCP_API PcpNodeRef PcpNodeRef::GetOriginNode | ( | ) | const |
Returns the immediate origin node for this node. The origin node is the node that caused this node to be brought into the prim index. In most cases, this is the same as the parent node. For implied inherits, the origin is the node from which this node was propagated.
PCP_API PcpNodeRef PcpNodeRef::GetOriginRootNode | ( | ) | const |
Walk up to the root origin node for this node. This is the very first node that caused this node to be added to the graph. For instance, the root origin node of an implied inherit is the original inherit node.
|
inline |
PCP_API PcpNodeRef PcpNodeRef::GetParentNode | ( | ) | const |
Returns this node's immediate parent node. Will return NULL if this node is a root node.
Returns the path for the site this node represents.
Returns the path for this node's site when it was introduced.
PCP_API SdfPermission PcpNodeRef::GetPermission | ( | ) | const |
Get the site this node represents.
PCP_API PcpNodeRef PcpNodeRef::GetRootNode | ( | ) | const |
Walk up to the root node of this expression.
Returns this node's index among siblings with the same arc type at this node's origin.
PCP_API PcpLayerStackSite PcpNodeRef::GetSite | ( | ) | const |
Get the site this node represents.
PCP_API size_t PcpNodeRef::GetSpecContributionRestrictedDepth | ( | ) | const |
Returns the namespace depth (i.e., the path element count) of this node's path when it was restricted from contributing opinions for composition. If this spec has no such restriction, returns 0.
Note that unlike the value returned by GetNamespaceDepth, this value does include variant selections.
Returns a value that uniquely identifies this node.
PCP_API bool PcpNodeRef::HasSpecs | ( | ) | const |
Get the site this node represents.
PCP_API bool PcpNodeRef::HasSymmetry | ( | ) | const |
Get the site this node represents.
PCP_API PcpNodeRef PcpNodeRef::InsertChild | ( | const PcpLayerStackSite & | site, |
const PcpArc & | arc, | ||
PcpErrorBasePtr * | error | ||
) |
Inserts a new child node for site
, connected to this node via arc
.
PCP_API PcpNodeRef PcpNodeRef::InsertChildSubgraph | ( | const PcpPrimIndex_GraphRefPtr & | subgraph, |
const PcpArc & | arc, | ||
PcpErrorBasePtr * | error | ||
) |
Inserts subgraph
as a child of this node, with the root node of subtree
connected to this node via arc
.
PCP_API bool PcpNodeRef::IsCulled | ( | ) | const |
Get the site this node represents.
PCP_API bool PcpNodeRef::IsDueToAncestor | ( | ) | const |
Get the site this node represents.
PCP_API bool PcpNodeRef::IsInert | ( | ) | const |
Get the site this node represents.
PCP_API bool PcpNodeRef::IsRestricted | ( | ) | const |
Get the site this node represents.
PCP_API bool PcpNodeRef::IsRootNode | ( | ) | const |
Returns true if this node is the root node of the prim index graph.
|
inline |
|
inline |
PCP_API bool PcpNodeRef::operator< | ( | const PcpNodeRef & | rhs | ) | const |
Returns true if this node is 'less' than rhs
. The ordering of nodes is arbitrary and does not indicate the relative strength of the nodes.
|
inline |
|
inline |
|
inline |
|
inline |
Get/set whether this node is culled. If a node is culled, it and all descendant nodes provide no opinions to the index. A culled node is also considered inert.
Returns true if this node has opinions authored for composition, false otherwise.
Get/set whether this node provides any symmetry opinions, either directly or from a namespace ancestor.
Get/set whether this node is inert. An inert node never provides any opinions to a prim index. Such a node may exist purely as a marker to represent certain composition structure, but should never contribute opinions.
Get/set whether this node was introduced by being copied from its namespace ancestor, or directly by an arc at this level of namespace.
PCP_API void PcpNodeRef::SetPermission | ( | SdfPermission | perm | ) |
Get/set the permission for this node. This indicates whether specs on this node can be accessed from other nodes.
Get/set whether this node is restricted. A restricted node is a node that cannot contribute opinions to the index due to permissions.
Set this node's contribution restriction depth.
Note that this function typically does not need to be called, since functions that restrict contributions (e.g., SetInert) automatically set the restriction depth appropriately.
|
friend |
|
friend |
|
friend |
|
friend |