From 05db9e9b995d9933082cb82ca5427520335bb481 Mon Sep 17 00:00:00 2001 From: Christoph Haag Date: Tue, 16 Jan 2024 03:09:07 +0100 Subject: [PATCH] u/space_overseer: Create STAGE as pose space when stage_supported on head --- src/xrt/auxiliary/util/u_space_overseer.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/xrt/auxiliary/util/u_space_overseer.c b/src/xrt/auxiliary/util/u_space_overseer.c index e19fe241a..20e2cc857 100644 --- a/src/xrt/auxiliary/util/u_space_overseer.c +++ b/src/xrt/auxiliary/util/u_space_overseer.c @@ -817,8 +817,14 @@ u_space_overseer_legacy_setup(struct u_space_overseer *uso, xrt_space_reference(&uso->base.semantic.local, NULL); xrt_space_reference(&uso->base.semantic.unbounded, NULL); - // Assume the root space is the center of the stage space. - xrt_space_reference(&uso->base.semantic.stage, uso->base.semantic.root); + if (head != NULL && head->stage_supported) { + // stage space is a pose space + u_space_overseer_create_pose_space(uso, head, XRT_INPUT_GENERIC_STAGE_SPACE_POSE, + &uso->base.semantic.stage); + } else { + // Assume the root space is the center of the stage space. + xrt_space_reference(&uso->base.semantic.stage, uso->base.semantic.root); + } // If the system wants to support the space, set root as unbounded. if (root_is_unbounded) {