Loading...
Searching...
No Matches
backPlateAPI.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 USDGEOM_GENERATED_BACKPLATEAPI_H
8#define USDGEOM_GENERATED_BACKPLATEAPI_H
9
11
12#include "pxr/pxr.h"
13#include "pxr/usd/usdGeom/api.h"
15#include "pxr/usd/usd/prim.h"
16#include "pxr/usd/usd/stage.h"
18
20
21
22#include "pxr/base/vt/value.h"
23
24#include "pxr/base/gf/vec3d.h"
25#include "pxr/base/gf/vec3f.h"
27
28#include "pxr/base/tf/token.h"
29#include "pxr/base/tf/type.h"
30
31PXR_NAMESPACE_OPEN_SCOPE
32
33class SdfAssetPath;
34
35// -------------------------------------------------------------------------- //
36// BACKPLATEAPI //
37// -------------------------------------------------------------------------- //
38
84{
85public:
90
101 const UsdPrim& prim=UsdPrim(), const TfToken &name=TfToken())
102 : UsdAPISchemaBase(prim, /*instanceName*/ name)
103 { }
104
110 const UsdSchemaBase& schemaObj, const TfToken &name)
111 : UsdAPISchemaBase(schemaObj, /*instanceName*/ name)
112 { }
113
115 USDGEOM_API
117
121 USDGEOM_API
122 static const TfTokenVector &
123 GetSchemaAttributeNames(bool includeInherited=true);
124
130 USDGEOM_API
131 static TfTokenVector
132 GetSchemaAttributeNames(bool includeInherited, const TfToken &instanceName);
133
135 TfToken GetName() const {
136 return _GetInstanceName();
137 }
138
153 USDGEOM_API
155 Get(const UsdStagePtr &stage, const SdfPath &path);
156
159 USDGEOM_API
161 Get(const UsdPrim &prim, const TfToken &name);
162
165 USDGEOM_API
166 static std::vector<UsdGeomBackPlateAPI>
167 GetAll(const UsdPrim &prim);
168
171 USDGEOM_API
172 static bool
174
178 USDGEOM_API
179 static bool
180 IsBackPlateAPIPath(const SdfPath &path, TfToken *name);
181
198 USDGEOM_API
199 static bool
200 CanApply(const UsdPrim &prim, const TfToken &name,
201 std::string *whyNot=nullptr);
202
222 USDGEOM_API
223 static UsdGeomBackPlateAPI
224 Apply(const UsdPrim &prim, const TfToken &name);
225
226protected:
230 USDGEOM_API
232
233private:
234 // needs to invoke _GetStaticTfType.
235 friend class UsdSchemaRegistry;
236 USDGEOM_API
237 static const TfType &_GetStaticTfType();
238
239 static bool _IsTypedSchema();
240
241 // override SchemaBase virtuals.
242 USDGEOM_API
243 const TfType &_GetTfType() const override;
244
245public:
246 // --------------------------------------------------------------------- //
247 // SCALETWEAK
248 // --------------------------------------------------------------------- //
258 USDGEOM_API
260
266 USDGEOM_API
267 UsdAttribute CreateScaleTweakAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
268
269public:
270 // --------------------------------------------------------------------- //
271 // ROTATEXYZTWEAK
272 // --------------------------------------------------------------------- //
281 USDGEOM_API
283
289 USDGEOM_API
290 UsdAttribute CreateRotateXYZTweakAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
291
292public:
293 // --------------------------------------------------------------------- //
294 // TRANSLATETWEAK
295 // --------------------------------------------------------------------- //
304 USDGEOM_API
306
312 USDGEOM_API
313 UsdAttribute CreateTranslateTweakAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
314
315public:
316 // --------------------------------------------------------------------- //
317 // IMAGE
318 // --------------------------------------------------------------------- //
330 USDGEOM_API
332
338 USDGEOM_API
339 UsdAttribute CreateImageAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
340
341public:
342 // --------------------------------------------------------------------- //
343 // ALPHAIMAGE
344 // --------------------------------------------------------------------- //
360 USDGEOM_API
362
368 USDGEOM_API
369 UsdAttribute CreateAlphaImageAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
370
371public:
372 // --------------------------------------------------------------------- //
373 // DEPTHIMAGE
374 // --------------------------------------------------------------------- //
389 USDGEOM_API
391
397 USDGEOM_API
398 UsdAttribute CreateDepthImageAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
399
400public:
401 // --------------------------------------------------------------------- //
402 // DEPTHMINOFFSET
403 // --------------------------------------------------------------------- //
412 USDGEOM_API
414
420 USDGEOM_API
421 UsdAttribute CreateDepthMinOffsetAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
422
423public:
424 // --------------------------------------------------------------------- //
425 // DEPTHNORMALIZINGFACTOR
426 // --------------------------------------------------------------------- //
434 USDGEOM_API
436
442 USDGEOM_API
443 UsdAttribute CreateDepthNormalizingFactorAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
444
445public:
446 // --------------------------------------------------------------------- //
447 // DEPTHCAMERASPACEOFFSET
448 // --------------------------------------------------------------------- //
456 USDGEOM_API
458
464 USDGEOM_API
465 UsdAttribute CreateDepthCameraSpaceOffsetAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
466
467public:
468 // --------------------------------------------------------------------- //
469 // LUMAGAIN
470 // --------------------------------------------------------------------- //
480 USDGEOM_API
482
488 USDGEOM_API
489 UsdAttribute CreateLumaGainAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
490
491public:
492 // --------------------------------------------------------------------- //
493 // LUMALIFT
494 // --------------------------------------------------------------------- //
504 USDGEOM_API
506
512 USDGEOM_API
513 UsdAttribute CreateLumaLiftAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
514
515public:
516 // --------------------------------------------------------------------- //
517 // LUMAGAMMA
518 // --------------------------------------------------------------------- //
528 USDGEOM_API
530
536 USDGEOM_API
537 UsdAttribute CreateLumaGammaAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
538
539public:
540 // --------------------------------------------------------------------- //
541 // PLATEVISIBILITY
542 // --------------------------------------------------------------------- //
552 USDGEOM_API
554
560 USDGEOM_API
561 UsdAttribute CreatePlateVisibilityAttr(VtValue const &defaultValue = VtValue(), bool writeSparsely=false) const;
562
563public:
564 // ===================================================================== //
565 // Feel free to add custom code below this line, it will be preserved by
566 // the code generator.
567 //
568 // Just remember to:
569 // - Close the class declaration with };
570 // - Close the namespace with PXR_NAMESPACE_CLOSE_SCOPE
571 // - Close the include guard with #endif
572 // ===================================================================== //
573 // --(BEGIN CUSTOM CODE)--
574
580 USDGEOM_API
581 float ComputeEffectiveDimension(bool computeWidth, UsdTimeCode time) const;
582
586 USDGEOM_API
587 void SetAspectRatio(float width, float height, UsdTimeCode time) const;
588
592 USDGEOM_API
594
597 USDGEOM_API
599
603 USDGEOM_API
605
608 USDGEOM_API
610};
611
612PXR_NAMESPACE_CLOSE_SCOPE
613
614#endif
Basic type for a vector of 3 float components.
Definition vec3f.h:46
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
Token for efficient comparison, assignment, and hashing of known strings.
Definition token.h:71
TfType represents a dynamic runtime type.
Definition type.h:48
The base class for all API schemas.
const TfToken & _GetInstanceName() const
Returns the instance name of the API schema object belonging to a multiple-apply API schema.
Scenegraph object for authoring and retrieving numeric, string, and array valued data,...
Definition attribute.h:183
This schema specifies a back plate i.e.
USDGEOM_API UsdAttribute CreatePlateVisibilityAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetPlateVisibilityAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
USDGEOM_API UsdAttribute CreateDepthMinOffsetAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetDepthMinOffsetAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
UsdGeomBackPlateAPI(const UsdSchemaBase &schemaObj, const TfToken &name)
Construct a UsdGeomBackPlateAPI on the prim held by schemaObj with name name.
USDGEOM_API float ComputeEffectiveDimension(bool computeWidth, UsdTimeCode time) const
Returns the height of the plate.
USDGEOM_API UsdAttribute CreateLumaGainAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetLumaGainAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
USDGEOM_API UsdAttribute CreateTranslateTweakAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetTranslateTweakAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
USDGEOM_API UsdAttribute CreateRotateXYZTweakAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetRotateXYZTweakAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
TfToken GetName() const
Returns the name of this multiple-apply schema instance.
USDGEOM_API UsdAttribute CreateScaleTweakAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetScaleTweakAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
static USDGEOM_API std::vector< UsdGeomBackPlateAPI > GetAll(const UsdPrim &prim)
Return a vector of all named instances of UsdGeomBackPlateAPI on the given prim.
static const UsdSchemaKind schemaKind
Compile time constant representing what kind of schema this class is.
USDGEOM_API UsdAttribute GetDepthMinOffsetAttr() const
Offset to shift the depth values if minimum value of current range is not set at 0 if needed.
USDGEOM_API UsdAttribute GetDepthImageAttr() const
File path to a single-channel texture that describes the depth associated with the image if one exist...
USDGEOM_API UsdAttribute GetPlateVisibilityAttr() const
Toggles the visibility of the back plate to all cameras, only the owning camera, or no cameras.
USDGEOM_API void SetWorldSpacePosition(GfVec3f pos, UsdTimeCode time) const
Computes and sets backplate tweak::translate such that the back plate will be positioned at the desir...
USDGEOM_API UsdAttribute GetTranslateTweakAttr() const
The (X,Y,Z) translation of the plate about its center after it has been translated by the focus dista...
USDGEOM_API UsdAttribute GetLumaGainAttr() const
Scales the per-channel upper bound of the normalized signal before gamma, analogous to per-channel ex...
USDGEOM_API GfVec3f GetWorldSpacePosition(UsdTimeCode time) const
Computes and returns the position of the backplate in world space.
UsdGeomBackPlateAPI(const UsdPrim &prim=UsdPrim(), const TfToken &name=TfToken())
Construct a UsdGeomBackPlateAPI on UsdPrim prim with name name .
USDGEOM_API UsdAttribute CreateLumaLiftAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetLumaLiftAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
USDGEOM_API UsdSchemaKind _GetSchemaKind() const override
Returns the kind of schema this class belongs to.
USDGEOM_API UsdAttribute CreateLumaGammaAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetLumaGammaAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
static USDGEOM_API bool IsSchemaPropertyBaseName(const TfToken &baseName)
Checks if the given name baseName is the base name of a property of BackPlateAPI.
static USDGEOM_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...
USDGEOM_API UsdAttribute CreateAlphaImageAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetAlphaImageAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
USDGEOM_API UsdAttribute GetAlphaImageAttr() const
Asset path to channel representing the opacity of the back plate.
USDGEOM_API UsdAttribute CreateDepthCameraSpaceOffsetAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetDepthCameraSpaceOffsetAttr(), and also Create vs Get Property Methods for when to use Get vs C...
USDGEOM_API UsdAttribute GetRotateXYZTweakAttr() const
The (X,Y,Z) rotation of the plate about its center in degrees.
USDGEOM_API UsdAttribute GetImageAttr() const
Asset path to the file containing a texture or sequence of textures.
static USDGEOM_API UsdGeomBackPlateAPI Apply(const UsdPrim &prim, const TfToken &name)
Applies this multiple-apply API schema to the given prim along with the given instance name,...
virtual USDGEOM_API ~UsdGeomBackPlateAPI()
Destructor.
USDGEOM_API UsdAttribute GetLumaLiftAttr() const
Raises or lowers the signal floor (black level) of the normalized value prior to the gain and gamma s...
USDGEOM_API void SetAspectRatio(float width, float height, UsdTimeCode time) const
Computes and sets backplate tweak::scale such that the back plate will have the desired width and hei...
static USDGEOM_API bool IsBackPlateAPIPath(const SdfPath &path, TfToken *name)
Checks if the given path path is of an API schema of type BackPlateAPI.
static USDGEOM_API UsdGeomBackPlateAPI Get(const UsdPrim &prim, const TfToken &name)
Return a UsdGeomBackPlateAPI with name name holding the prim prim.
USDGEOM_API UsdAttribute GetLumaGammaAttr() const
Per-channel power applied to the normalized RGB signal after lift and gain.
static USDGEOM_API bool CanApply(const UsdPrim &prim, const TfToken &name, std::string *whyNot=nullptr)
Returns true if this multiple-apply API schema can be applied, with the given instance name,...
USDGEOM_API UsdAttribute CreateDepthNormalizingFactorAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetDepthNormalizingFactorAttr(), and also Create vs Get Property Methods for when to use Get vs C...
USDGEOM_API UsdAttribute GetScaleTweakAttr() const
The (X,Y) scale of the plate about its center.
USDGEOM_API UsdAttribute CreateImageAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetImageAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
static USDGEOM_API UsdGeomBackPlateAPI Get(const UsdStagePtr &stage, const SdfPath &path)
Return a UsdGeomBackPlateAPI holding the prim adhering to this schema at path on stage.
USDGEOM_API UsdAttribute CreateDepthImageAttr(VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
See GetDepthImageAttr(), and also Create vs Get Property Methods for when to use Get vs Create.
static USDGEOM_API TfTokenVector GetSchemaAttributeNames(bool includeInherited, const TfToken &instanceName)
Return a vector of names of all pre-declared attributes for this schema class and all its ancestor cl...
USDGEOM_API GfVec3f GetCameraSpacePosition(UsdTimeCode time) const
Computes and returns the position of the backplate in camera space.
USDGEOM_API UsdAttribute GetDepthNormalizingFactorAttr() const
Value to scale the texture depth value if needed.
USDGEOM_API void SetCameraSpacePosition(GfVec3f pos, UsdTimeCode time) const
Computes and sets backplate tweak::translate such that the back plate will be positioned at the desir...
USDGEOM_API UsdAttribute GetDepthCameraSpaceOffsetAttr() const
Offset to shift the depth into camera space if needed.
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...
Represent a time value, which may be either numeric, holding a double value, or a sentinel value UsdT...
Definition timeCode.h:72
Provides a container which may hold any type, and provides introspection and iteration over array typ...
Definition value.h:90
UsdSchemaKind
An enum representing which kind of schema a given schema class belongs to.
Definition common.h:112
@ MultipleApplyAPI
Multiple Apply API Schema.
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