mirror of
https://gitlab.freedesktop.org/monado/monado.git
synced 2024-12-26 17:37:34 +00:00
d/wmr: Fix pose correction from Basalt
There was a confusion about whether this was needed for some apps. It was.
This commit is contained in:
parent
e7c3376612
commit
604815cb51
|
@ -969,6 +969,10 @@ wmr_hmd_get_3dof_tracked_pose(struct xrt_device *xdev,
|
|||
XRT_MAYBE_UNUSED static inline struct xrt_pose
|
||||
wmr_hmd_correct_pose_from_basalt(struct xrt_pose pose)
|
||||
{
|
||||
struct xrt_quat q = {0.70710678, 0, 0, 0.70710678};
|
||||
math_quat_rotate(&q, &pose.orientation, &pose.orientation);
|
||||
math_quat_rotate_vec3(&q, &pose.position, &pose.position);
|
||||
|
||||
// Correct swapped axes
|
||||
pose.position.y = -pose.position.y;
|
||||
pose.position.z = -pose.position.z;
|
||||
|
|
Loading…
Reference in a new issue