HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
UsdSkelTopology Class Reference

#include <topology.h>

Public Member Functions

 UsdSkelTopology ()=default
 Construct an empty topology. More...
 
USDSKEL_API UsdSkelTopology (TfSpan< const TfToken > paths)
 
USDSKEL_API UsdSkelTopology (TfSpan< const SdfPath > paths)
 Construct a skel topology from paths, an array of joint paths. More...
 
USDSKEL_API UsdSkelTopology (const VtIntArray &parentIndices)
 
USDSKEL_API bool Validate (std::string *reason=nullptr) const
 
const VtIntArray & GetParentIndices () const
 
size_t GetNumJoints () const
 
size_t size () const
 
int GetParent (size_t index) const
 
bool IsRoot (size_t index) const
 Returns true if the index'th joint is a root joint. More...
 
bool operator== (const UsdSkelTopology &o) const
 
bool operator!= (const UsdSkelTopology &o) const
 

Detailed Description

Object holding information describing skeleton topology. This provides the hierarchical information needed to reason about joint relationships in a manner suitable to computations.

Definition at line 45 of file topology.h.

Constructor & Destructor Documentation

UsdSkelTopology::UsdSkelTopology ( )
default

Construct an empty topology.

USDSKEL_API UsdSkelTopology::UsdSkelTopology ( TfSpan< const TfToken paths)

Construct a skel topology from paths, an array holding ordered joint paths as tokens. Internally, each token must be converted to an SdfPath. If SdfPath objects are already accessible, it is more efficient to use the construct taking an SdfPath array.

USDSKEL_API UsdSkelTopology::UsdSkelTopology ( TfSpan< const SdfPath paths)

Construct a skel topology from paths, an array of joint paths.

USDSKEL_API UsdSkelTopology::UsdSkelTopology ( const VtIntArray &  parentIndices)

Construct a skel topology from an array of parent indices. For each joint, this provides the parent index of that joint, or -1 if none.

Member Function Documentation

size_t UsdSkelTopology::GetNumJoints ( ) const
inline

Definition at line 77 of file topology.h.

int UsdSkelTopology::GetParent ( size_t  index) const
inline

Returns the parent joint of the index'th joint, Returns -1 for joints with no parent (roots).

Definition at line 100 of file topology.h.

const VtIntArray& UsdSkelTopology::GetParentIndices ( ) const
inline

Definition at line 75 of file topology.h.

bool UsdSkelTopology::IsRoot ( size_t  index) const
inline

Returns true if the index'th joint is a root joint.

Definition at line 86 of file topology.h.

bool UsdSkelTopology::operator!= ( const UsdSkelTopology o) const
inline

Definition at line 90 of file topology.h.

bool UsdSkelTopology::operator== ( const UsdSkelTopology o) const
size_t UsdSkelTopology::size ( void  ) const
inline

Definition at line 79 of file topology.h.

USDSKEL_API bool UsdSkelTopology::Validate ( std::string reason = nullptr) const

Validate the topology. If validation is unsuccessful, a reason why will be written to reason, if provided.


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