mirror of
https://gitlab.freedesktop.org/monado/monado.git
synced 2025-01-29 18:08:29 +00:00
st/oxr: Improve the xrGetReferenceSpaceBoundsRect stub-ness
This commit is contained in:
parent
d693bc2ef9
commit
f0e160f45c
3
doc/changes/state_trackers/mr.359.7.md
Normal file
3
doc/changes/state_trackers/mr.359.7.md
Normal file
|
@ -0,0 +1,3 @@
|
|||
OpenXR: Make the function `xrGetReferenceSpaceBoundsRect` at least conform to
|
||||
the spec without actually implementing it, currently we do not track bounds in
|
||||
Monado.
|
|
@ -83,10 +83,25 @@ oxr_xrGetReferenceSpaceBoundsRect(XrSession session,
|
|||
struct oxr_logger log;
|
||||
OXR_VERIFY_SESSION_AND_INIT_LOG(&log, session, sess,
|
||||
"xrGetReferenceSpaceBoundsRect");
|
||||
OXR_VERIFY_ARG_NOT_NULL(&log, bounds);
|
||||
|
||||
//! @todo Implement
|
||||
return oxr_error(&log, XR_ERROR_FUNCTION_UNSUPPORTED,
|
||||
" not implemented");
|
||||
|
||||
switch (referenceSpaceType) {
|
||||
case XR_REFERENCE_SPACE_TYPE_VIEW:
|
||||
case XR_REFERENCE_SPACE_TYPE_LOCAL:
|
||||
case XR_REFERENCE_SPACE_TYPE_STAGE: break;
|
||||
default:
|
||||
return oxr_error(&log, XR_ERROR_VALIDATION_FAILURE,
|
||||
"(referenceSpaceType == 0x%08x) is not a "
|
||||
"valid XrReferenceSpaceType",
|
||||
referenceSpaceType);
|
||||
}
|
||||
|
||||
bounds->width = 0.0;
|
||||
bounds->height = 0.0;
|
||||
|
||||
// Silently return that the bounds aren't available.
|
||||
return XR_SPACE_BOUNDS_UNAVAILABLE;
|
||||
}
|
||||
|
||||
XrResult
|
||||
|
|
Loading…
Reference in a new issue