|
Monado OpenXR Runtime
|

Public Member Functions | |
| void | m_relation_history_create (struct m_relation_history **rh) |
| Creates an opaque relation_history object. More... | |
| bool | m_relation_history_push (struct m_relation_history *rh, struct xrt_space_relation const *in_relation, int64_t timestamp) |
| Pushes a new pose to the history. More... | |
| enum m_relation_history_result | m_relation_history_get (const struct m_relation_history *rh, int64_t at_timestamp_ns, struct xrt_space_relation *out_relation) |
| Interpolates or extrapolates to the desired timestamp. More... | |
| bool | m_relation_history_estimate_motion (struct m_relation_history *rh, const struct xrt_space_relation *in_relation, int64_t timestamp, struct xrt_space_relation *out_relation) |
| Estimates the movement (velocity and angular velocity) of a new relation based on the latest relation found in the buffer (as returned by m_relation_history_get_latest). More... | |
| bool | m_relation_history_get_latest (const struct m_relation_history *rh, int64_t *out_time_ns, struct xrt_space_relation *out_relation) |
| Get the latest report in the buffer, if any. More... | |
| uint32_t | m_relation_history_get_size (const struct m_relation_history *rh) |
| Returns the number of items in the history. More... | |
| void | m_relation_history_clear (struct m_relation_history *rh) |
| Clears the history from all of the items. More... | |
| void | m_relation_history_destroy (struct m_relation_history **rh) |
| Destroys an opaque relation_history object. More... | |
Data Fields | |
| HistoryBuffer< struct relation_history_entry, BufLen > | impl |
| os::Mutex | mutex |
Related Functions | |
(Note that these are not member functions.) | |
| enum | m_relation_history_result |
| Describes how the resulting space relation for the desired time stamp was generated. More... | |
| void m_relation_history_clear | ( | struct m_relation_history * | rh | ) |
Clears the history from all of the items.
| void m_relation_history_create | ( | struct m_relation_history ** | rh | ) |
Creates an opaque relation_history object.
Referenced by u_tracked_imu_3dof_create().
| void m_relation_history_destroy | ( | struct m_relation_history ** | rh | ) |
Destroys an opaque relation_history object.
References U_LOG_E.
| bool m_relation_history_estimate_motion | ( | struct m_relation_history * | rh, |
| const struct xrt_space_relation * | in_relation, | ||
| int64_t | timestamp, | ||
| struct xrt_space_relation * | out_relation | ||
| ) |
Estimates the movement (velocity and angular velocity) of a new relation based on the latest relation found in the buffer (as returned by m_relation_history_get_latest).
Read-only on m_relation_history and in_relation. Copies in_relation->pose to out_relation->pose, and writes new flags and linear/angular velocities to out_relation->pose. OK to alias in_relation and out_relation.
| enum m_relation_history_result m_relation_history_get | ( | const struct m_relation_history * | rh, |
| int64_t | at_timestamp_ns, | ||
| struct xrt_space_relation * | out_relation | ||
| ) |
Interpolates or extrapolates to the desired timestamp.
Read-only operation - doesn't remove anything from the buffer or anything like that - you can call this as often as you want.
| bool m_relation_history_get_latest | ( | const struct m_relation_history * | rh, |
| int64_t * | out_time_ns, | ||
| struct xrt_space_relation * | out_relation | ||
| ) |
Get the latest report in the buffer, if any.
| rh | self | |
| [out] | out_time_ns | Populated with the latest report time, if any |
| [out] | out_relation | Populated with the latest relation, if any |
| uint32_t m_relation_history_get_size | ( | const struct m_relation_history * | rh | ) |
Returns the number of items in the history.
| bool m_relation_history_push | ( | struct m_relation_history * | rh, |
| struct xrt_space_relation const * | in_relation, | ||
| int64_t | timestamp | ||
| ) |
Pushes a new pose to the history.
If the history is full, it will also pop a pose out of the other side of the buffer.
|
related |
Describes how the resulting space relation for the desired time stamp was generated.