All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
spatialAudio.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 USDMEDIA_GENERATED_SPATIALAUDIO_H
8#define USDMEDIA_GENERATED_SPATIALAUDIO_H
9
11
12#include "pxr/pxr.h"
13#include "pxr/usd/usdMedia/api.h"
15#include "pxr/usd/usd/prim.h"
16#include "pxr/usd/usd/stage.h"
18
19#include "pxr/base/vt/value.h"
20
21#include "pxr/base/gf/vec3d.h"
22#include "pxr/base/gf/vec3f.h"
24
25#include "pxr/base/tf/token.h"
26#include "pxr/base/tf/type.h"
27
28PXR_NAMESPACE_OPEN_SCOPE
29
30class SdfAssetPath;
31
32// -------------------------------------------------------------------------- //
33// SPATIALAUDIO //
34// -------------------------------------------------------------------------- //
35
92{
93public:
97 static const UsdSchemaKind schemaKind = UsdSchemaKind::ConcreteTyped;
98
103 explicit UsdMediaSpatialAudio(const UsdPrim& prim=UsdPrim())
104 : UsdGeomXformable(prim)
105 {
106 }
107
111 explicit UsdMediaSpatialAudio(const UsdSchemaBase& schemaObj)
112 : UsdGeomXformable(schemaObj)
113 {
114 }
115
117 USDMEDIA_API
119
123 USDMEDIA_API
124 static const TfTokenVector &
125 GetSchemaAttributeNames(bool includeInherited=true);
126
136 USDMEDIA_API
138 Get(const UsdStagePtr &stage, const SdfPath &path);
139
162 USDMEDIA_API
164 Define(const UsdStagePtr &stage, const SdfPath &path);
165
166protected:
170 USDMEDIA_API
172
173private:
174 // needs to invoke _GetStaticTfType.
175 friend class UsdSchemaRegistry;
176 USDMEDIA_API
177 static const TfType &_GetStaticTfType();
178
179 static bool _IsTypedSchema();
180
181 // override SchemaBase virtuals.
182 USDMEDIA_API
183 const TfType &_GetTfType() const override;
184
185public:
186 // --------------------------------------------------------------------- //
187 // FILEPATH
188 // --------------------------------------------------------------------- //
204 USDMEDIA_API
206
212 USDMEDIA_API
213 UsdAttribute CreateFilePathAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
214
215public:
216 // --------------------------------------------------------------------- //
217 // AURALMODE
218 // --------------------------------------------------------------------- //
238 USDMEDIA_API
240
246 USDMEDIA_API
247 UsdAttribute CreateAuralModeAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
248
249public:
250 // --------------------------------------------------------------------- //
251 // PLAYBACKMODE
252 // --------------------------------------------------------------------- //
279 USDMEDIA_API
281
287 USDMEDIA_API
288 UsdAttribute CreatePlaybackModeAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
289
290public:
291 // --------------------------------------------------------------------- //
292 // STARTTIME
293 // --------------------------------------------------------------------- //
310 USDMEDIA_API
312
318 USDMEDIA_API
319 UsdAttribute CreateStartTimeAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
320
321public:
322 // --------------------------------------------------------------------- //
323 // ENDTIME
324 // --------------------------------------------------------------------- //
344 USDMEDIA_API
346
352 USDMEDIA_API
353 UsdAttribute CreateEndTimeAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
354
355public:
356 // --------------------------------------------------------------------- //
357 // MEDIAOFFSET
358 // --------------------------------------------------------------------- //
373 USDMEDIA_API
375
381 USDMEDIA_API
382 UsdAttribute CreateMediaOffsetAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
383
384public:
385 // --------------------------------------------------------------------- //
386 // GAIN
387 // --------------------------------------------------------------------- //
397 USDMEDIA_API
399
405 USDMEDIA_API
406 UsdAttribute CreateGainAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
407
408public:
409 // ===================================================================== //
410 // Feel free to add custom code below this line, it will be preserved by
411 // the code generator.
412 //
413 // Just remember to:
414 // - Close the class declaration with };
415 // - Close the namespace with PXR_NAMESPACE_CLOSE_SCOPE
416 // - Close the include guard with #endif
417 // ===================================================================== //
418 // --(BEGIN CUSTOM CODE)--
419};
420
421PXR_NAMESPACE_CLOSE_SCOPE
422
423#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
Scenegraph object for authoring and retrieving numeric, string, and array valued data,...
Definition: attribute.h:160
Base class for all transformable prims, which allows arbitrary sequences of component affine transfor...
Definition: xformable.h:236
The SpatialAudio primitive defines basic properties for encoding playback of an audio file or stream ...
Definition: spatialAudio.h:92
USDMEDIA_API UsdAttribute GetMediaOffsetAttr() const
Expressed in seconds, mediaOffset specifies the offset from the referenced audio file's beginning at ...
static const UsdSchemaKind schemaKind
Compile time constant representing what kind of schema this class is.
Definition: spatialAudio.h:97
USDMEDIA_API UsdSchemaKind _GetSchemaKind() const override
Returns the kind of schema this class belongs to.
USDMEDIA_API UsdAttribute GetAuralModeAttr() const
Determines how audio should be played.
USDMEDIA_API UsdAttribute CreateMediaOffsetAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetMediaOffsetAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
static USDMEDIA_API UsdMediaSpatialAudio Get(const UsdStagePtr &stage, const SdfPath &path)
Return a UsdMediaSpatialAudio holding the prim adhering to this schema at path on stage.
static USDMEDIA_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...
USDMEDIA_API UsdAttribute GetFilePathAttr() const
Path to the audio file.
USDMEDIA_API UsdAttribute GetGainAttr() const
Multiplier on the incoming audio signal.
USDMEDIA_API UsdAttribute GetEndTimeAttr() const
Expressed in the timeCodesPerSecond of the containing stage, endTime specifies when the audio stream ...
USDMEDIA_API UsdAttribute CreateEndTimeAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetEndTimeAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
USDMEDIA_API UsdAttribute CreateAuralModeAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetAuralModeAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
UsdMediaSpatialAudio(const UsdSchemaBase &schemaObj)
Construct a UsdMediaSpatialAudio on the prim held by schemaObj .
Definition: spatialAudio.h:111
USDMEDIA_API UsdAttribute GetStartTimeAttr() const
Expressed in the timeCodesPerSecond of the containing stage, startTime specifies when the audio strea...
USDMEDIA_API UsdAttribute CreateFilePathAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetFilePathAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
UsdMediaSpatialAudio(const UsdPrim &prim=UsdPrim())
Construct a UsdMediaSpatialAudio on UsdPrim prim .
Definition: spatialAudio.h:103
USDMEDIA_API UsdAttribute CreateGainAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetGainAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
USDMEDIA_API UsdAttribute CreateStartTimeAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetStartTimeAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
USDMEDIA_API UsdAttribute GetPlaybackModeAttr() const
Along with startTime and endTime, determines when the audio playback should start and stop during the...
virtual USDMEDIA_API ~UsdMediaSpatialAudio()
Destructor.
static USDMEDIA_API UsdMediaSpatialAudio Define(const UsdStagePtr &stage, const SdfPath &path)
Attempt to ensure a UsdPrim adhering to this schema at path is defined (according to UsdPrim::IsDefin...
USDMEDIA_API UsdAttribute CreatePlaybackModeAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetPlaybackModeAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
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...
Provides a container which may hold any type, and provides introspection and iteration over array typ...
Definition: value.h:147
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