mirror of
https://gitlab.freedesktop.org/monado/monado.git
synced 2025-01-21 06:01:43 +00:00
st/oxr: Check if relating space to itself first
This commit is contained in:
parent
ddb528f002
commit
f18c190eaa
|
@ -187,7 +187,9 @@ oxr_space_ref_relation(struct oxr_logger *log,
|
||||||
math_relation_reset(out_relation);
|
math_relation_reset(out_relation);
|
||||||
|
|
||||||
|
|
||||||
if (space == XR_REFERENCE_SPACE_TYPE_VIEW) {
|
if (space == baseSpc) {
|
||||||
|
// math_relation_reset() sets to identity.
|
||||||
|
} else if (space == XR_REFERENCE_SPACE_TYPE_VIEW) {
|
||||||
oxr_session_get_view_pose_at(log, sess, time,
|
oxr_session_get_view_pose_at(log, sess, time,
|
||||||
&out_relation->pose);
|
&out_relation->pose);
|
||||||
|
|
||||||
|
@ -258,8 +260,6 @@ oxr_space_ref_relation(struct oxr_logger *log,
|
||||||
XRT_SPACE_RELATION_BITMASK_NONE;
|
XRT_SPACE_RELATION_BITMASK_NONE;
|
||||||
return XR_SUCCESS;
|
return XR_SUCCESS;
|
||||||
}
|
}
|
||||||
} else if (space == baseSpc) {
|
|
||||||
// math_relation_reset() sets to identity.
|
|
||||||
} else {
|
} else {
|
||||||
out_relation->relation_flags = XRT_SPACE_RELATION_BITMASK_NONE;
|
out_relation->relation_flags = XRT_SPACE_RELATION_BITMASK_NONE;
|
||||||
return XR_SUCCESS;
|
return XR_SUCCESS;
|
||||||
|
|
Loading…
Reference in a new issue