Loading...
Searching...
No Matches
fieldBase.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 USDVOL_GENERATED_FIELDBASE_H
8#define USDVOL_GENERATED_FIELDBASE_H
9
11
12#include "pxr/pxr.h"
13#include "pxr/usd/usdVol/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// FIELDBASE //
33// -------------------------------------------------------------------------- //
34
43{
44public:
48 static const UsdSchemaKind schemaKind = UsdSchemaKind::AbstractTyped;
49
54 explicit UsdVolFieldBase(const UsdPrim& prim=UsdPrim())
56 {
57 }
58
62 explicit UsdVolFieldBase(const UsdSchemaBase& schemaObj)
63 : UsdVolVolumeFieldBase(schemaObj)
64 {
65 }
66
68 USDVOL_API
70
74 USDVOL_API
75 static const TfTokenVector &
76 GetSchemaAttributeNames(bool includeInherited=true);
77
87 USDVOL_API
88 static UsdVolFieldBase
89 Get(const UsdStagePtr &stage, const SdfPath &path);
90
91
92protected:
96 USDVOL_API
97 UsdSchemaKind _GetSchemaKind() const override;
98
99private:
100 // needs to invoke _GetStaticTfType.
101 friend class UsdSchemaRegistry;
102 USDVOL_API
103 static const TfType &_GetStaticTfType();
104
105 static bool _IsTypedSchema();
106
107 // override SchemaBase virtuals.
108 USDVOL_API
109 const TfType &_GetTfType() const override;
110
111public:
112 // ===================================================================== //
113 // Feel free to add custom code below this line, it will be preserved by
114 // the code generator.
115 //
116 // Just remember to:
117 // - Close the class declaration with };
118 // - Close the namespace with PXR_NAMESPACE_CLOSE_SCOPE
119 // - Close the include guard with #endif
120 // ===================================================================== //
121 // --(BEGIN CUSTOM CODE)--
122};
123
124PXR_NAMESPACE_CLOSE_SCOPE
125
126#endif
Contains an asset path and optional evaluated and resolved paths.
Definition: assetPath.h:79
A path value used to locate objects in layers or scenegraphs.
Definition: path.h:281
TfType represents a dynamic runtime type.
Definition: type.h:48
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...
UsdVolFieldBase(const UsdPrim &prim=UsdPrim())
Construct a UsdVolFieldBase on UsdPrim prim .
Definition: fieldBase.h:54
UsdVolFieldBase(const UsdSchemaBase &schemaObj)
Construct a UsdVolFieldBase on the prim held by schemaObj .
Definition: fieldBase.h:62
USDVOL_API UsdSchemaKind _GetSchemaKind() const override
Returns the kind of schema this class belongs to.
static const UsdSchemaKind schemaKind
Compile time constant representing what kind of schema this class is.
Definition: fieldBase.h:48
static USDVOL_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...
virtual USDVOL_API ~UsdVolFieldBase()
Destructor.
static USDVOL_API UsdVolFieldBase Get(const UsdStagePtr &stage, const SdfPath &path)
Return a UsdVolFieldBase holding the prim adhering to this schema at path on stage.
Base class for volume field primitives.
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