Open 3D Engine PhysX Gem API Reference  24.09
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
PhysX::JointRequests Class Referenceabstract

Interface to communicate with PhysX joint's motor. More...

#include <PhysXJointRequestsBus.h>

Inherits AZ::EBusTraits.

Public Types

using BusIdType = AZ::EntityComponentIdPair
 

Public Member Functions

virtual float GetPosition () const =0
 
virtual float GetVelocity () const =0
 
virtual void SetVelocity (float velocity)=0
 
virtual AZ::Transform GetTransform () const =0
 Gets local transformation of joint.
 
virtual AZStd::pair< float, float > GetLimits () const =0
 Gets limits on active joint's axis.
 
virtual void SetMaximumForce (float force)=0
 

Static Public Attributes

static constexpr AZ::EBusAddressPolicy AddressPolicy = AZ::EBusAddressPolicy::ById
 

Detailed Description

Interface to communicate with PhysX joint's motor.

Member Function Documentation

◆ GetPosition()

virtual float PhysX::JointRequests::GetPosition ( ) const
pure virtual

Returns current position from joint. It is a relative position of the entity in the direction of the free axis of the joint. For a hinge joint it is a twist angle (in radians), for the prismatic joint it is travel (in meters).

◆ GetVelocity()

virtual float PhysX::JointRequests::GetVelocity ( ) const
pure virtual

Returns velocity. It is a relative velocity of the entity in the direction of the free axis of the joint. For a hinge joint rotation velocity in radians per second. For prismatic joint it is linear velocity in meters per second.

◆ SetMaximumForce()

virtual void PhysX::JointRequests::SetMaximumForce ( float  force)
pure virtual

Sets maximum motor force.

Parameters
forcein Newtons (for prismatic joint) or Newton-meters (for hinge joint).

◆ SetVelocity()

virtual void PhysX::JointRequests::SetVelocity ( float  velocity)
pure virtual

Sets drive velocity.

Parameters
velocityvelocity in meters per second (for prismatic joint) or radians per second (for hinge joint)

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