GREM 3.12.0
Game/Rendering Engine Modules for C++
Loading...
Searching...
No Matches
grem::resource::Model::PhysicsJoint Struct Reference

Physics joint between two physics objects in a model. More...

#include <GREM/resource/Model.hpp>

Public Attributes

Pair< PhysicsObjectIndex > objectIndices
 Ordered pair of indices of the connected physics objects, or the maximum value if there is no object.
Pair< JointIndex > jointIndices
 Ordered pair of indices of the joints serving as the attachment frames.
bool driveIgnoresMassX: 1
 Whether the value computed from the spring equation is the linear acceleration or the force to apply along the X axis.
bool driveIgnoresMassY: 1
 Whether the value computed from the spring equation is the linear acceleration or the force to apply along the Y axis.
bool driveIgnoresMassZ: 1
 Whether the value computed from the spring equation is the linear acceleration or the force to apply along the Z axis.
bool driveIgnoresMomentOfInertiaX: 1
 Whether the value computed from the spring equation is the angular acceleration or the torque to apply about the X axis.
bool driveIgnoresMomentOfInertiaY: 1
 Whether the value computed from the spring equation is the angular acceleration or the torque to apply about the Y axis.
bool driveIgnoresMomentOfInertiaZ: 1
 Whether the value computed from the spring equation is the angular acceleration or the torque to apply about the Z axis.
bool enableCollision: 1
 Allow the connected objects to collide.
vec3 minDistances
 The minimum of the allowed range of relative distance along each axis.
vec3 maxDistances
 The maximum of the allowed range of relative distance along each axis.
vec3 minAngles
 The minimum of the allowed range of relative angle about each axis.
vec3 maxAngles
 The maximum of the allowed range of relative angle about each axis.
vec3 linearStiffnesses
 The spring constants used to calculate a restorative force along each axis when the joint is extended beyond the limit.
vec3 angularStiffnesses
 The spring constants used to calculate a restorative torque about each axis when the joint is extended beyond the limit.
vec3 linearDamping
 Damping applied to the linear velocity along each axis when the joint is extended beyond the limit.
vec3 angularDamping
 Damping applied to the angular velocity about each axis when the joint is extended beyond the limit.
vec3 maxForce
 Maximum force applied along each driven linear axis.
vec3 maxTorque
 Maximum torque applied along each driven angular axis.
vec3 targetPosition
 Target translation along each axis that the drive attempts to achieve.
vec3 targetAngles
 Target angle about each axis that the drive attempts to achieve.
vec3 targetLinearVelocity
 Target linear velocity along each axis that this drive attempts to achieve.
vec3 targetAngularVelocity
 Target angular velocity about each axis that this drive attempts to achieve.
vec3 linearDriveDamping
 The damping of the linear drive, scaling the force based on the target linear velocity.
vec3 angularDriveDamping
 The damping of the angular drive, scaling the torque based on the target angular velocity.

Detailed Description

Physics joint between two physics objects in a model.

Member Data Documentation

◆ objectIndices

Pair<PhysicsObjectIndex> grem::resource::Model::PhysicsJoint::objectIndices

Ordered pair of indices of the connected physics objects, or the maximum value if there is no object.

◆ jointIndices

Pair<JointIndex> grem::resource::Model::PhysicsJoint::jointIndices

Ordered pair of indices of the joints serving as the attachment frames.

◆ driveIgnoresMassX

bool grem::resource::Model::PhysicsJoint::driveIgnoresMassX

Whether the value computed from the spring equation is the linear acceleration or the force to apply along the X axis.

◆ driveIgnoresMassY

bool grem::resource::Model::PhysicsJoint::driveIgnoresMassY

Whether the value computed from the spring equation is the linear acceleration or the force to apply along the Y axis.

◆ driveIgnoresMassZ

bool grem::resource::Model::PhysicsJoint::driveIgnoresMassZ

Whether the value computed from the spring equation is the linear acceleration or the force to apply along the Z axis.

◆ driveIgnoresMomentOfInertiaX

bool grem::resource::Model::PhysicsJoint::driveIgnoresMomentOfInertiaX

Whether the value computed from the spring equation is the angular acceleration or the torque to apply about the X axis.

◆ driveIgnoresMomentOfInertiaY

bool grem::resource::Model::PhysicsJoint::driveIgnoresMomentOfInertiaY

Whether the value computed from the spring equation is the angular acceleration or the torque to apply about the Y axis.

◆ driveIgnoresMomentOfInertiaZ

bool grem::resource::Model::PhysicsJoint::driveIgnoresMomentOfInertiaZ

Whether the value computed from the spring equation is the angular acceleration or the torque to apply about the Z axis.

◆ enableCollision

bool grem::resource::Model::PhysicsJoint::enableCollision

Allow the connected objects to collide.

◆ minDistances

vec3 grem::resource::Model::PhysicsJoint::minDistances

The minimum of the allowed range of relative distance along each axis.

◆ maxDistances

vec3 grem::resource::Model::PhysicsJoint::maxDistances

The maximum of the allowed range of relative distance along each axis.

◆ minAngles

vec3 grem::resource::Model::PhysicsJoint::minAngles

The minimum of the allowed range of relative angle about each axis.

◆ maxAngles

vec3 grem::resource::Model::PhysicsJoint::maxAngles

The maximum of the allowed range of relative angle about each axis.

◆ linearStiffnesses

vec3 grem::resource::Model::PhysicsJoint::linearStiffnesses

The spring constants used to calculate a restorative force along each axis when the joint is extended beyond the limit.

◆ angularStiffnesses

vec3 grem::resource::Model::PhysicsJoint::angularStiffnesses

The spring constants used to calculate a restorative torque about each axis when the joint is extended beyond the limit.

◆ linearDamping

vec3 grem::resource::Model::PhysicsJoint::linearDamping

Damping applied to the linear velocity along each axis when the joint is extended beyond the limit.

◆ angularDamping

vec3 grem::resource::Model::PhysicsJoint::angularDamping

Damping applied to the angular velocity about each axis when the joint is extended beyond the limit.

◆ maxForce

vec3 grem::resource::Model::PhysicsJoint::maxForce

Maximum force applied along each driven linear axis.

◆ maxTorque

vec3 grem::resource::Model::PhysicsJoint::maxTorque

Maximum torque applied along each driven angular axis.

◆ targetPosition

vec3 grem::resource::Model::PhysicsJoint::targetPosition

Target translation along each axis that the drive attempts to achieve.

◆ targetAngles

vec3 grem::resource::Model::PhysicsJoint::targetAngles

Target angle about each axis that the drive attempts to achieve.

◆ targetLinearVelocity

vec3 grem::resource::Model::PhysicsJoint::targetLinearVelocity

Target linear velocity along each axis that this drive attempts to achieve.

◆ targetAngularVelocity

vec3 grem::resource::Model::PhysicsJoint::targetAngularVelocity

Target angular velocity about each axis that this drive attempts to achieve.

◆ linearDriveDamping

vec3 grem::resource::Model::PhysicsJoint::linearDriveDamping

The damping of the linear drive, scaling the force based on the target linear velocity.

◆ angularDriveDamping

vec3 grem::resource::Model::PhysicsJoint::angularDriveDamping

The damping of the angular drive, scaling the torque based on the target angular velocity.


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