From eaf6efda72a6315f39e36f9083e5b5b3bf37ec7a Mon Sep 17 00:00:00 2001 From: Patrick Nicolas Date: Sun, 2 Jun 2024 23:19:04 +0200 Subject: [PATCH] Update Monado --- CMakeLists.txt | 2 +- server/driver/wivrn_comp_target.cpp | 6 +++--- server/driver/wivrn_hmd.cpp | 1 + 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 933199ba..161bdc7f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -177,7 +177,7 @@ FetchContent_Declare(implot URL https://github.com/epezent/implot/archive # Server dependencies FetchContent_Declare(monado GIT_REPOSITORY https://gitlab.freedesktop.org/monado/monado - GIT_TAG 9f4f2541a672152c4d0255f48bf4298b8888cd63 + GIT_TAG 95331593e23ddb78cc0f6b0d712fdc3234e1fdd2 PATCH_COMMAND ${CMAKE_CURRENT_LIST_DIR}/patches/apply.sh ${CMAKE_CURRENT_LIST_DIR}/patches/monado/ ) diff --git a/server/driver/wivrn_comp_target.cpp b/server/driver/wivrn_comp_target.cpp index f7b8b240..21c1e52b 100644 --- a/server/driver/wivrn_comp_target.cpp +++ b/server/driver/wivrn_comp_target.cpp @@ -267,7 +267,7 @@ static bool comp_wivrn_check_ready(struct comp_target * ct) { const auto & slot = cn->c->base.slot; if (slot.layer_count > 1 or - slot.layers[0].data.type != XRT_LAYER_STEREO_PROJECTION) + slot.layers[0].data.type != XRT_LAYER_PROJECTION) { // We are not in the trivial single stereo projection layer // reprojection must be done @@ -545,8 +545,8 @@ static VkResult comp_wivrn_present(struct comp_target * ct, view_info.pose[eye] = xrt_cast(slot.poses[eye]); if (cn->c->debug.atw_off) { - const auto & stereo = slot.layers[0].data.stereo; - view_info.pose[eye] = xrt_cast(eye ? stereo.r.pose : stereo.l.pose); + const auto & proj = slot.layers[0].data.proj; + view_info.pose[eye] = xrt_cast(proj.v[eye].pose); } else { diff --git a/server/driver/wivrn_hmd.cpp b/server/driver/wivrn_hmd.cpp index 967f1bc6..0fc2fec2 100644 --- a/server/driver/wivrn_hmd.cpp +++ b/server/driver/wivrn_hmd.cpp @@ -226,6 +226,7 @@ wivrn_hmd::wivrn_hmd(std::shared_ptr cnx, foveated_eye_height += foveated_eye_height % 2; // Setup info. + hmd->view_count = 2; hmd->blend_modes[0] = XRT_BLEND_MODE_OPAQUE; hmd->blend_mode_count = 1; hmd->distortion.models = XRT_DISTORTION_MODEL_COMPUTE;