A class that describes the physical and simulated properties of a type of material.
More...
#include <omPhysicsMaterial.h>
A class that describes the physical and simulated properties of a type of material.
om::physics::base::PhysicsMaterial::PhysicsMaterial |
( |
| ) |
|
Create a material with the default material parameters.
Float om::physics::base::PhysicsMaterial::getDensity |
( |
| ) |
const |
|
inline |
Return the density of this material in mass units (kg) over length units (m) cubed.
void om::physics::base::PhysicsMaterial::setDensity |
( |
Float |
newDensity | ) |
|
|
inline |
Set the density of this material in mass units (kg) over length units (m) cubed.
The density of the material is clamped to the range [0,+infinity).
Float om::physics::base::PhysicsMaterial::getElasticity |
( |
| ) |
const |
|
inline |
Return the coefficient of restitution of this material.
A value of 0 indicates that this material undergoes totally inelastic collisions, while a value of 1 indicates that collisions are highly elastic.
void om::physics::base::PhysicsMaterial::setElasticity |
( |
Float |
newElasticity | ) |
|
|
inline |
Set the coefficient of restitution of this material.
This value is clamped to the range [0,1]. A value of 0 indicates that this material undergoes totally inelastic collisions, while a value of 1 indicates that collisions are perfectly elastic.
Float om::physics::base::PhysicsMaterial::getCaptureVelocity |
( |
| ) |
const |
|
inline |
Return the capture velocity of this material.
void om::physics::base::PhysicsMaterial::setCaptureVelocity |
( |
Float |
newCaptureVelocity | ) |
|
|
inline |
Return the capture velocity of this material.
This value is clamped to the range [0,infinity).
Float om::physics::base::PhysicsMaterial::getYieldVelocity |
( |
| ) |
const |
|
inline |
Return the yield velocity of this material.
void om::physics::base::PhysicsMaterial::setYieldVelocity |
( |
Float |
newYieldVelocity | ) |
|
|
inline |
Return the yield velocity of this material.
This value is clamped to the range [0,infinity).
Float om::physics::base::PhysicsMaterial::getKineticFriction |
( |
| ) |
const |
|
inline |
Return the coefficient of kinetic friction for this material.
This value indicates the coefficient of friction to be used when the relative speed between two objects is greater than the static friction threshold.
void om::physics::base::PhysicsMaterial::setKineticFriction |
( |
Float |
newKineticFriction | ) |
|
|
inline |
Set the coefficient of kinetic friction for this material.
This value indicates the coefficient of friction to be used when the relative speed between two objects is greater than the static friction threshold. This value is clamped to the range of [0,+infinity).
Float om::physics::base::PhysicsMaterial::getStaticFriction |
( |
| ) |
const |
|
inline |
Return the coefficient of static friction for this material.
This value indicates the coefficient of friction to be used when the relative speed between two objects is less than the static friction threshold.
void om::physics::base::PhysicsMaterial::setStaticFriction |
( |
Float |
newStaticFriction | ) |
|
|
inline |
Set the coefficient of static friction for this material.
This value indicates the coefficient of friction to be used when the relative speed between two objects is less than the static friction threshold. This value is clamped to the range of [0,+infinity).
Float om::physics::base::PhysicsMaterial::getStaticFrictionThreshold |
( |
| ) |
const |
|
inline |
Return the relative speed threshold below which static friction is in effect.
This value indicates the maximum relative speed at the point of collision between two objects where static friction has effect. If the relative speed is greater than this value, kinetic friction is observed.
void om::physics::base::PhysicsMaterial::setStaticFrictionThreshold |
( |
Float |
newStaticFrictionThreshold | ) |
|
|
inline |
Set the relative speed threshold below which static friction is in effect.
This value indicates the maximum relative speed at the point of collision between two objects where static friction has effect. If the relative speed is greater than this value, kinetic friction is observed. This value is clamped to the range of [0,+infinity).
Float om::physics::base::PhysicsMaterial::getRollingFriction |
( |
| ) |
const |
|
inline |
Return the coefficient of rolling friction for this material.
void om::physics::base::PhysicsMaterial::setRollingFriction |
( |
Float |
newRollingFriction | ) |
|
|
inline |
Set the coefficient of rolling friction for this material.
This value is clamped to the range of [0,+infinity).
The default physics material.
const ResourceType om::physics::base::PhysicsMaterial::RESOURCE_TYPE |
|
static |
The resource type for a physics material.
The documentation for this class was generated from the following file: