This document is for a version of USD that is under development. See this page for the current release.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
root.h
Go to the documentation of this file.
1//
2// Copyright 2016 Pixar
3//
4// Licensed under the terms set forth in the LICENSE.txt file available at
5// https://openusd.org/license.
6//
7#ifndef USDSKEL_GENERATED_ROOT_H
8#define USDSKEL_GENERATED_ROOT_H
9
11
12#include "pxr/pxr.h"
13#include "pxr/usd/usdSkel/api.h"
15#include "pxr/usd/usd/prim.h"
16#include "pxr/usd/usd/stage.h"
17
18#include "pxr/base/vt/value.h"
19
20#include "pxr/base/gf/vec3d.h"
21#include "pxr/base/gf/vec3f.h"
23
24#include "pxr/base/tf/token.h"
25#include "pxr/base/tf/type.h"
26
27PXR_NAMESPACE_OPEN_SCOPE
28
29class SdfAssetPath;
30
31// -------------------------------------------------------------------------- //
32// SKELROOT //
33// -------------------------------------------------------------------------- //
34
47{
48public:
52 static const UsdSchemaKind schemaKind = UsdSchemaKind::ConcreteTyped;
53
58 explicit UsdSkelRoot(const UsdPrim& prim=UsdPrim())
59 : UsdGeomBoundable(prim)
60 {
61 }
62
66 explicit UsdSkelRoot(const UsdSchemaBase& schemaObj)
67 : UsdGeomBoundable(schemaObj)
68 {
69 }
70
72 USDSKEL_API
73 virtual ~UsdSkelRoot();
74
78 USDSKEL_API
79 static const TfTokenVector &
80 GetSchemaAttributeNames(bool includeInherited=true);
81
91 USDSKEL_API
92 static UsdSkelRoot
93 Get(const UsdStagePtr &stage, const SdfPath &path);
94
117 USDSKEL_API
118 static UsdSkelRoot
119 Define(const UsdStagePtr &stage, const SdfPath &path);
120
121protected:
125 USDSKEL_API
127
128private:
129 // needs to invoke _GetStaticTfType.
130 friend class UsdSchemaRegistry;
131 USDSKEL_API
132 static const TfType &_GetStaticTfType();
133
134 static bool _IsTypedSchema();
135
136 // override SchemaBase virtuals.
137 USDSKEL_API
138 const TfType &_GetTfType() const override;
139
140public:
141 // ===================================================================== //
142 // Feel free to add custom code below this line, it will be preserved by
143 // the code generator.
144 //
145 // Just remember to:
146 // - Close the class declaration with };
147 // - Close the namespace with PXR_NAMESPACE_CLOSE_SCOPE
148 // - Close the include guard with #endif
149 // ===================================================================== //
150 // --(BEGIN CUSTOM CODE)--
151
154 USDSKEL_API
155 static UsdSkelRoot Find(const UsdPrim& prim);
156};
157
158PXR_NAMESPACE_CLOSE_SCOPE
159
160#endif
Contains an asset path and an optional resolved path.
Definition: assetPath.h:30
A path value used to locate objects in layers or scenegraphs.
Definition: path.h:274
TfType represents a dynamic runtime type.
Definition: type.h:48
Boundable introduces the ability for a prim to persistently cache a rectilinear, local-space,...
Definition: boundable.h:66
UsdPrim is the sole persistent scenegraph object on a UsdStage, and is the embodiment of a "Prim" as ...
Definition: prim.h:117
The base class for all schema types in Usd.
Definition: schemaBase.h:39
Singleton registry that provides access to schema type information and the prim definitions for regis...
Boundable prim type used to identify a scope beneath which skeletally-posed primitives are defined.
Definition: root.h:47
UsdSkelRoot(const UsdSchemaBase &schemaObj)
Construct a UsdSkelRoot on the prim held by schemaObj .
Definition: root.h:66
static USDSKEL_API const TfTokenVector & GetSchemaAttributeNames(bool includeInherited=true)
Return a vector of names of all pre-declared attributes for this schema class and all its ancestor cl...
static const UsdSchemaKind schemaKind
Compile time constant representing what kind of schema this class is.
Definition: root.h:52
virtual USDSKEL_API ~UsdSkelRoot()
Destructor.
USDSKEL_API UsdSchemaKind _GetSchemaKind() const override
Returns the kind of schema this class belongs to.
UsdSkelRoot(const UsdPrim &prim=UsdPrim())
Construct a UsdSkelRoot on UsdPrim prim .
Definition: root.h:58
static USDSKEL_API UsdSkelRoot Define(const UsdStagePtr &stage, const SdfPath &path)
Attempt to ensure a UsdPrim adhering to this schema at path is defined (according to UsdPrim::IsDefin...
static USDSKEL_API UsdSkelRoot Get(const UsdStagePtr &stage, const SdfPath &path)
Return a UsdSkelRoot holding the prim adhering to this schema at path on stage.
static USDSKEL_API UsdSkelRoot Find(const UsdPrim &prim)
Returns the skel root at or above prim, or an invalid schema object if no ancestor prim is defined ...
UsdSchemaKind
An enum representing which kind of schema a given schema class belongs to.
Definition: common.h:112
TfToken class for efficient string referencing and hashing, plus conversions to and from stl string c...
std::vector< TfToken > TfTokenVector
Convenience types.
Definition: token.h:440