2-D velocity related data structure. More...
#include <Velocity.hpp>
Public Attributes | |
| LinearVelocity2 | linear |
| Linear velocity. More... | |
| AngularVelocity | angular |
| Angular velocity. More... | |
Related Functions | |
(Note that these are not member functions.) | |
| PLAYRHO_CONSTEXPR bool | operator== (const Velocity &lhs, const Velocity &rhs) |
| Equality operator. More... | |
| PLAYRHO_CONSTEXPR bool | operator!= (const Velocity &lhs, const Velocity &rhs) |
| Inequality operator. More... | |
| PLAYRHO_CONSTEXPR Velocity & | operator*= (Velocity &lhs, const Real rhs) |
| Multiplication assignment operator. More... | |
| PLAYRHO_CONSTEXPR Velocity & | operator/= (Velocity &lhs, const Real rhs) |
| Division assignment operator. More... | |
| PLAYRHO_CONSTEXPR Velocity & | operator+= (Velocity &lhs, const Velocity &rhs) |
| Addition assignment operator. More... | |
| PLAYRHO_CONSTEXPR Velocity | operator+ (const Velocity &lhs, const Velocity &rhs) |
| Addition operator. More... | |
| PLAYRHO_CONSTEXPR Velocity & | operator-= (Velocity &lhs, const Velocity &rhs) |
| Subtraction assignment operator. More... | |
| PLAYRHO_CONSTEXPR Velocity | operator- (const Velocity &lhs, const Velocity &rhs) |
| Subtraction operator. More... | |
| PLAYRHO_CONSTEXPR Velocity | operator- (const Velocity &value) |
| Negation operator. More... | |
| PLAYRHO_CONSTEXPR Velocity | operator+ (const Velocity &value) |
| Positive operator. More... | |
| PLAYRHO_CONSTEXPR Velocity | operator* (const Velocity &lhs, const Real rhs) |
| Multiplication operator. More... | |
| PLAYRHO_CONSTEXPR Velocity | operator* (const Real lhs, const Velocity &rhs) |
| Multiplication operator. More... | |
| PLAYRHO_CONSTEXPR Velocity | operator/ (const Velocity &lhs, const Real rhs) |
| Division operator. More... | |
| template<> | |
| PLAYRHO_CONSTEXPR bool | IsValid (const d2::Velocity &value) noexcept |
| Determines if the given value is valid. More... | |
| Velocity | Cap (Velocity velocity, Time h, MovementConf conf) noexcept |
| Caps velocity. More... | |
Detailed Description
2-D velocity related data structure.
- Note
- This data structure is 12-bytes (with 4-byte Real on at least one 64-bit platform).
Definition at line 35 of file Velocity.hpp.
Friends And Related Function Documentation
◆ operator==()
|
related |
Equality operator.
Definition at line 43 of file Velocity.hpp.
◆ operator!=()
|
related |
Inequality operator.
Definition at line 50 of file Velocity.hpp.
◆ operator*=()
|
related |
Multiplication assignment operator.
Definition at line 57 of file Velocity.hpp.
◆ operator/=()
|
related |
Division assignment operator.
Definition at line 66 of file Velocity.hpp.
◆ operator+=()
|
related |
Addition assignment operator.
Definition at line 75 of file Velocity.hpp.
◆ operator+() [1/2]
|
related |
Addition operator.
Definition at line 84 of file Velocity.hpp.
◆ operator-=()
|
related |
Subtraction assignment operator.
Definition at line 91 of file Velocity.hpp.
◆ operator-() [1/2]
|
related |
Subtraction operator.
Definition at line 100 of file Velocity.hpp.
◆ operator-() [2/2]
|
related |
Negation operator.
Definition at line 107 of file Velocity.hpp.
◆ operator+() [2/2]
|
related |
Positive operator.
Definition at line 114 of file Velocity.hpp.
◆ operator*() [1/2]
|
related |
Multiplication operator.
Definition at line 121 of file Velocity.hpp.
◆ operator*() [2/2]
|
related |
Multiplication operator.
Definition at line 128 of file Velocity.hpp.
◆ operator/()
|
related |
Division operator.
Definition at line 135 of file Velocity.hpp.
◆ IsValid()
|
related |
Determines if the given value is valid.
Definition at line 152 of file Velocity.hpp.
◆ Cap()
|
related |
Caps velocity.
Enforces maximums on the given velocity.
- Parameters
-
velocity Velocity to cap. Behavior is undefined if this value is invalid. h Time elapsed to get velocity for. Behavior is undefined if this value is invalid. conf Movement configuration. This defines caps on linear and angular speeds.
Member Data Documentation
◆ linear
| LinearVelocity2 playrho::d2::Velocity::linear |
Linear velocity.
Definition at line 37 of file Velocity.hpp.
◆ angular
| AngularVelocity playrho::d2::Velocity::angular |
Angular velocity.
Definition at line 38 of file Velocity.hpp.
The documentation for this struct was generated from the following files:
- Common/Velocity.hpp
- Dynamics/Body.hpp

