All Classes Files Functions Variables Pages
PhysxSchemaPhysxVehicleControllerAPI Class Reference

PhysX vehicle controller that samples user input to drive the vehicle. More...

Inherits UsdAPISchemaBase.

Public Member Functions

 PhysxSchemaPhysxVehicleControllerAPI (const UsdPrim &prim=UsdPrim())
 Construct a PhysxSchemaPhysxVehicleControllerAPI on UsdPrim prim . More...
 
 PhysxSchemaPhysxVehicleControllerAPI (const UsdSchemaBase &schemaObj)
 Construct a PhysxSchemaPhysxVehicleControllerAPI on the prim held by schemaObj . More...
 
virtual PHYSXSCHEMA_API ~PhysxSchemaPhysxVehicleControllerAPI ()
 Destructor. More...
 
PHYSXSCHEMA_API UsdAttribute GetAcceleratorAttr () const
 Driven vehicle. More...
 
PHYSXSCHEMA_API UsdAttribute CreateAcceleratorAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
 See GetAcceleratorAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More...
 
PHYSXSCHEMA_API UsdAttribute GetBrake0Attr () const
 Brake control for braking system "brakes0" (see PhysxVehicleBrakesAPI) that triggers the connected brakes and defines the brake strength. More...
 
PHYSXSCHEMA_API UsdAttribute CreateBrake0Attr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
 See GetBrake0Attr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More...
 
PHYSXSCHEMA_API UsdAttribute GetBrake1Attr () const
 Brake control for braking system "brakes1" (see PhysxVehicleBrakesAPI) that triggers the connected brakes and defines the brake strength. More...
 
PHYSXSCHEMA_API UsdAttribute CreateBrake1Attr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
 See GetBrake1Attr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More...
 
PHYSXSCHEMA_API UsdAttribute GetBrakeAttr () const
 Deprecated. More...
 
PHYSXSCHEMA_API UsdAttribute CreateBrakeAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
 See GetBrakeAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More...
 
PHYSXSCHEMA_API UsdAttribute GetHandbrakeAttr () const
 Deprecated. More...
 
PHYSXSCHEMA_API UsdAttribute CreateHandbrakeAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
 See GetHandbrakeAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More...
 
PHYSXSCHEMA_API UsdAttribute GetSteerAttr () const
 Steer control for the steering system (see PhysxVehicleSteeringAPI). More...
 
PHYSXSCHEMA_API UsdAttribute CreateSteerAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
 See GetSteerAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More...
 
PHYSXSCHEMA_API UsdAttribute GetSteerLeftAttr () const
 Deprecated. More...
 
PHYSXSCHEMA_API UsdAttribute CreateSteerLeftAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
 See GetSteerLeftAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More...
 
PHYSXSCHEMA_API UsdAttribute GetSteerRightAttr () const
 Deprecated. More...
 
PHYSXSCHEMA_API UsdAttribute CreateSteerRightAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
 See GetSteerRightAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More...
 
PHYSXSCHEMA_API UsdAttribute GetTargetGearAttr () const
 Driven vehicle. More...
 
PHYSXSCHEMA_API UsdAttribute CreateTargetGearAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const
 See GetTargetGearAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More...
 

Static Public Member Functions

static PHYSXSCHEMA_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 classes. More...
 
static PHYSXSCHEMA_API
PhysxSchemaPhysxVehicleControllerAPI 
Get (const UsdStagePtr &stage, const SdfPath &path)
 Return a PhysxSchemaPhysxVehicleControllerAPI holding the prim adhering to this schema at path on stage. More...
 
static PHYSXSCHEMA_API bool CanApply (const UsdPrim &prim, std::string *whyNot=nullptr)
 Returns true if this single-apply API schema can be applied to the given prim. More...
 
static PHYSXSCHEMA_API
PhysxSchemaPhysxVehicleControllerAPI 
Apply (const UsdPrim &prim)
 Applies this single-apply API schema to the given prim. More...
 

Static Public Attributes

static const UsdSchemaKind schemaKind = UsdSchemaKind::SingleApplyAPI
 Compile time constant representing what kind of schema this class is. More...
 

Protected Member Functions

PHYSXSCHEMA_API UsdSchemaKind _GetSchemaKind () const override
 Returns the kind of schema this class belongs to. More...
 

Friends

class UsdSchemaRegistry
 

Detailed Description

PhysX vehicle controller that samples user input to drive the vehicle.

Has to be applied to a prim with PhysxVehicleAPI applied.

Definition at line 57 of file physxVehicleControllerAPI.h.

Constructor & Destructor Documentation

PhysxSchemaPhysxVehicleControllerAPI ( const UsdPrim &  prim = UsdPrim())
inlineexplicit

Construct a PhysxSchemaPhysxVehicleControllerAPI on UsdPrim prim .

Equivalent to PhysxSchemaPhysxVehicleControllerAPI::Get(prim.GetStage(), prim.GetPath()) for a valid prim, but will not immediately throw an error for an invalid prim

Definition at line 69 of file physxVehicleControllerAPI.h.

PhysxSchemaPhysxVehicleControllerAPI ( const UsdSchemaBase &  schemaObj)
inlineexplicit

Construct a PhysxSchemaPhysxVehicleControllerAPI on the prim held by schemaObj .

Should be preferred over PhysxSchemaPhysxVehicleControllerAPI(schemaObj.GetPrim()), as it preserves SchemaBase state.

Definition at line 77 of file physxVehicleControllerAPI.h.

virtual PHYSXSCHEMA_API ~PhysxSchemaPhysxVehicleControllerAPI ( )
virtual

Destructor.

Member Function Documentation

PHYSXSCHEMA_API UsdSchemaKind _GetSchemaKind ( ) const
overrideprotected

Returns the kind of schema this class belongs to.

See Also
UsdSchemaKind
static PHYSXSCHEMA_API PhysxSchemaPhysxVehicleControllerAPI Apply ( const UsdPrim &  prim)
static

Applies this single-apply API schema to the given prim.

This information is stored by adding "PhysxVehicleControllerAPI" to the token-valued, listOp metadata apiSchemas on the prim.

Returns
A valid PhysxSchemaPhysxVehicleControllerAPI object is returned upon success. An invalid (or empty) PhysxSchemaPhysxVehicleControllerAPI object is returned upon failure. See UsdPrim::ApplyAPI() for conditions resulting in failure.
See Also
UsdPrim::GetAppliedSchemas()
UsdPrim::HasAPI()
UsdPrim::CanApplyAPI()
UsdPrim::ApplyAPI()
UsdPrim::RemoveAPI()
static PHYSXSCHEMA_API bool CanApply ( const UsdPrim &  prim,
std::string *  whyNot = nullptr 
)
static

Returns true if this single-apply API schema can be applied to the given prim.

If this schema can not be a applied to the prim, this returns false and, if provided, populates whyNot with the reason it can not be applied.

Note that if CanApply returns false, that does not necessarily imply that calling Apply will fail. Callers are expected to call CanApply before calling Apply if they want to ensure that it is valid to apply a schema.

See Also
UsdPrim::GetAppliedSchemas()
UsdPrim::HasAPI()
UsdPrim::CanApplyAPI()
UsdPrim::ApplyAPI()
UsdPrim::RemoveAPI()
PHYSXSCHEMA_API UsdAttribute CreateAcceleratorAttr ( VtValue const &  defaultValue = VtValue(),
bool  writeSparsely = false 
) const

See GetAcceleratorAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.

If specified, author defaultValue as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely is true - the default for writeSparsely is false.

PHYSXSCHEMA_API UsdAttribute CreateBrake0Attr ( VtValue const &  defaultValue = VtValue(),
bool  writeSparsely = false 
) const

See GetBrake0Attr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.

If specified, author defaultValue as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely is true - the default for writeSparsely is false.

PHYSXSCHEMA_API UsdAttribute CreateBrake1Attr ( VtValue const &  defaultValue = VtValue(),
bool  writeSparsely = false 
) const

See GetBrake1Attr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.

If specified, author defaultValue as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely is true - the default for writeSparsely is false.

PHYSXSCHEMA_API UsdAttribute CreateBrakeAttr ( VtValue const &  defaultValue = VtValue(),
bool  writeSparsely = false 
) const

See GetBrakeAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.

If specified, author defaultValue as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely is true - the default for writeSparsely is false.

PHYSXSCHEMA_API UsdAttribute CreateHandbrakeAttr ( VtValue const &  defaultValue = VtValue(),
bool  writeSparsely = false 
) const

See GetHandbrakeAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.

If specified, author defaultValue as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely is true - the default for writeSparsely is false.

PHYSXSCHEMA_API UsdAttribute CreateSteerAttr ( VtValue const &  defaultValue = VtValue(),
bool  writeSparsely = false 
) const

See GetSteerAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.

If specified, author defaultValue as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely is true - the default for writeSparsely is false.

PHYSXSCHEMA_API UsdAttribute CreateSteerLeftAttr ( VtValue const &  defaultValue = VtValue(),
bool  writeSparsely = false 
) const

See GetSteerLeftAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.

If specified, author defaultValue as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely is true - the default for writeSparsely is false.

PHYSXSCHEMA_API UsdAttribute CreateSteerRightAttr ( VtValue const &  defaultValue = VtValue(),
bool  writeSparsely = false 
) const

See GetSteerRightAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.

If specified, author defaultValue as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely is true - the default for writeSparsely is false.

PHYSXSCHEMA_API UsdAttribute CreateTargetGearAttr ( VtValue const &  defaultValue = VtValue(),
bool  writeSparsely = false 
) const

See GetTargetGearAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.

If specified, author defaultValue as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely is true - the default for writeSparsely is false.

static PHYSXSCHEMA_API PhysxSchemaPhysxVehicleControllerAPI Get ( const UsdStagePtr &  stage,
const SdfPath &  path 
)
static

Return a PhysxSchemaPhysxVehicleControllerAPI holding the prim adhering to this schema at path on stage.

If no prim exists at path on stage, or if the prim at that path does not adhere to this schema, return an invalid schema object. This is shorthand for the following:

* PhysxSchemaPhysxVehicleControllerAPI(stage->GetPrimAtPath(path));
*
PHYSXSCHEMA_API UsdAttribute GetAcceleratorAttr ( ) const

Driven vehicle.

Throttle input, 0.0 to 1.0.

Declaration float physxVehicleController:accelerator = 0
C++ Type float
Usd Type SdfValueTypeNames->Float
PHYSXSCHEMA_API UsdAttribute GetBrake0Attr ( ) const

Brake control for braking system "brakes0" (see PhysxVehicleBrakesAPI) that triggers the connected brakes and defines the brake strength.

Value has to be in range [0.0, 1.0].

Declaration float physxVehicleController:brake0 = 0
C++ Type float
Usd Type SdfValueTypeNames->Float
PHYSXSCHEMA_API UsdAttribute GetBrake1Attr ( ) const

Brake control for braking system "brakes1" (see PhysxVehicleBrakesAPI) that triggers the connected brakes and defines the brake strength.

Value has to be in range [0.0, 1.0].

Declaration float physxVehicleController:brake1 = 0
C++ Type float
Usd Type SdfValueTypeNames->Float
PHYSXSCHEMA_API UsdAttribute GetBrakeAttr ( ) const

Deprecated.

Please use brake0/brake1 instead.

Driven vehicle. Brake input, 0.0 to 1.0.

Declaration float physxVehicleController:brake = 0
C++ Type float
Usd Type SdfValueTypeNames->Float
PHYSXSCHEMA_API UsdAttribute GetHandbrakeAttr ( ) const

Deprecated.

Please use brake0/brake1 instead.

Driven vehicle. Handbrake input, 0.0 to 1.0.

Declaration float physxVehicleController:handbrake = 0
C++ Type float
Usd Type SdfValueTypeNames->Float
static PHYSXSCHEMA_API const TfTokenVector& GetSchemaAttributeNames ( bool  includeInherited = true)
static

Return a vector of names of all pre-declared attributes for this schema class and all its ancestor classes.

Does not include attributes that may be authored by custom/extended methods of the schemas involved.

PHYSXSCHEMA_API UsdAttribute GetSteerAttr ( ) const

Steer control for the steering system (see PhysxVehicleSteeringAPI).

Defines the extent of the wheels' steer angles with respect to the maximum steer angle. Value has to be in range [-1.0, 1.0].

Declaration float physxVehicleController:steer = 0
C++ Type float
Usd Type SdfValueTypeNames->Float
PHYSXSCHEMA_API UsdAttribute GetSteerLeftAttr ( ) const

Deprecated.

Please use steer instead.

Driven vehicle. Left steering input. 0.0 to 1.0. Net steering is the aggregate of steerRight and steerLeft.

Declaration float physxVehicleController:steerLeft = 0
C++ Type float
Usd Type SdfValueTypeNames->Float
PHYSXSCHEMA_API UsdAttribute GetSteerRightAttr ( ) const

Deprecated.

Please use steer instead.

Driven vehicle. Right steering input, 0.0 to 1.0. Net steering is the aggregate of steerRight and steerLeft.

Declaration float physxVehicleController:steerRight = 0
C++ Type float
Usd Type SdfValueTypeNames->Float
PHYSXSCHEMA_API UsdAttribute GetTargetGearAttr ( ) const

Driven vehicle.

Desired gear to shift into. -1 = Reverse, 0 = Neutral, 1 = First etc. The special value 255 is used to denote automatic forward gear shifting (similar to <D> in automatic transmissions).

Note: if set to automatic gear shifting, the vehicle is expected to have an autobox defined (see PhysxVehicleAutoGearBoxAPI).

Note: please be aware that the target gear definition differs from the PhysX vehicle API.

Declaration int physxVehicleController:targetGear = 255
C++ Type int
Usd Type SdfValueTypeNames->Int

Member Data Documentation

const UsdSchemaKind schemaKind = UsdSchemaKind::SingleApplyAPI
static

Compile time constant representing what kind of schema this class is.

See Also
UsdSchemaKind

Definition at line 63 of file physxVehicleControllerAPI.h.


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