Merge remote-tracking branch 'upstream/master'

This commit is contained in:
Vindicus999
2026-03-21 02:23:03 +00:00
18 changed files with 113 additions and 59 deletions
+14
View File
@@ -282,6 +282,20 @@ FetchContent_Declare(monado
EXCLUDE_FROM_ALL
)
add_custom_target(wivrn-version ALL
COMMAND ${CMAKE_COMMAND}
-D GIT_EXECUTABLE=${GIT_EXECUTABLE}
-D INPUT_FILE=${CMAKE_CURRENT_SOURCE_DIR}/common/version.cpp.in
-D OUTPUT_FILE=${CMAKE_BINARY_DIR}/version.cpp
-D INPUT_FILE_1=${CMAKE_CURRENT_SOURCE_DIR}/server/u_git_tag.cpp.in
-D OUTPUT_FILE_1=${CMAKE_BINARY_DIR}/u_git_tag.cpp
-D GIT_DESC="${GIT_DESC}"
-D GIT_COMMIT="${GIT_COMMIT}"
-P ${CMAKE_SOURCE_DIR}/cmake/GitVersion.cmake
BYPRODUCTS ${CMAKE_BINARY_DIR}/version.cpp ${CMAKE_BINARY_DIR}/u_git_tag.cpp
SOURCES common/version.cpp.in server/u_git_tag.cpp.in
)
add_subdirectory(external)
if (NEED_COMMON)
add_subdirectory(common)
+1
View File
@@ -30,3 +30,4 @@ else()
endif()
configure_file(${INPUT_FILE} ${OUTPUT_FILE})
configure_file(${INPUT_FILE_1} ${OUTPUT_FILE_1})
+1 -14
View File
@@ -5,25 +5,12 @@ else()
FetchContent_MakeAvailable(boost)
endif()
add_custom_target(wivrn-version ALL
COMMAND ${CMAKE_COMMAND}
-D GIT_EXECUTABLE=${GIT_EXECUTABLE}
-D INPUT_FILE=${CMAKE_CURRENT_SOURCE_DIR}/version.cpp.in
-D OUTPUT_FILE=${CMAKE_CURRENT_BINARY_DIR}/version.cpp
-D CMAKE_PROJECT_VERSION=${CMAKE_PROJECT_VERSION}
-D GIT_DESC="${GIT_DESC}"
-D GIT_COMMIT="${GIT_COMMIT}"
-P ${CMAKE_SOURCE_DIR}/cmake/GitVersion.cmake
BYPRODUCTS ${CMAKE_CURRENT_BINARY_DIR}/version.cpp
SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/version.cpp.in
)
configure_file(wivrn_config.h.in wivrn_config.h)
add_library(wivrn-common-base STATIC EXCLUDE_FROM_ALL
utils/strings.cpp
utils/xdg_base_directory.cpp
${CMAKE_CURRENT_BINARY_DIR}/version.cpp
${CMAKE_BINARY_DIR}/version.cpp
)
add_library(wivrn-common STATIC EXCLUDE_FROM_ALL
+1 -1
View File
@@ -58,7 +58,7 @@
# Keep in sync with CMakeLists.txt monado rev
rev = lib.strings.trim (builtins.readFile ./monado-rev);
# Nix will output the correct hash when it doesn't match
hash = "sha256-aIHry5C30pZVIkB5fptJ0Ncbmg8EKf0M7evB4IJZEI0=";
hash = "sha256-M0SQMu1rgY++a+4r0DK//ralFEO5w7I3UrgLecoLO+A=";
};
};
+1 -1
View File
@@ -1 +1 @@
ee655a920cb4b50bafa2af2c92333a503e40cae6
ef152c973b94a313e1ba9552162818b5151ac671
@@ -1,4 +1,4 @@
From 563f347bf4d59b4a82144e25c3be894a0cd17c8d Mon Sep 17 00:00:00 2001
From 6317d6556f2510cc63aa5f71d86585830a38b2a1 Mon Sep 17 00:00:00 2001
From: Patrick Nicolas <patricknicolas@laposte.net>
Date: Tue, 22 Oct 2024 15:23:19 +0200
Subject: [PATCH 1/9] c/multi: early wake of compositor
@@ -10,7 +10,7 @@ Subject: [PATCH 1/9] c/multi: early wake of compositor
3 files changed, 41 insertions(+), 7 deletions(-)
diff --git a/src/xrt/compositor/multi/comp_multi_compositor.c b/src/xrt/compositor/multi/comp_multi_compositor.c
index 94cea110e..88347a092 100644
index 1fc135ce4..25b64aca8 100644
--- a/src/xrt/compositor/multi/comp_multi_compositor.c
+++ b/src/xrt/compositor/multi/comp_multi_compositor.c
@@ -236,7 +236,21 @@ wait_for_scheduled_free(struct multi_compositor *mc)
@@ -1,4 +1,4 @@
From 7d7c139b9ed03ec492256760c6acd1c7364c2e2a Mon Sep 17 00:00:00 2001
From 71b4f13a8b7cb90edf83f75bef8459d2db66c386 Mon Sep 17 00:00:00 2001
From: Patrick Nicolas <patricknicolas@laposte.net>
Date: Tue, 8 Oct 2024 22:13:15 +0200
Subject: [PATCH 2/9] Use extern socket fd
@@ -1,4 +1,4 @@
From 1328192bc28f312e728460d6c29ab150a9b655bd Mon Sep 17 00:00:00 2001
From d3fc5ebb88a59ce5fc1120ed33de921eec03384f Mon Sep 17 00:00:00 2001
From: galister <85970-galister@users.noreply.gitlab.freedesktop.org>
Date: Sat, 23 Nov 2024 02:42:12 +0900
Subject: [PATCH 3/9] change environment blend mode selection logic
@@ -1,4 +1,4 @@
From 18f87ff2f292e2f4cab8718601e6d5ba236a5013 Mon Sep 17 00:00:00 2001
From 42e1e561a98f5c9fd6f757232bd4821124ae9bb3 Mon Sep 17 00:00:00 2001
From: Patrick Nicolas <patricknicolas@laposte.net>
Date: Sat, 15 Mar 2025 22:19:48 +0100
Subject: [PATCH 4/9] st/oxr: forward 0 refresh rate
@@ -9,10 +9,10 @@ Subject: [PATCH 4/9] st/oxr: forward 0 refresh rate
2 files changed, 2 insertions(+), 6 deletions(-)
diff --git a/src/xrt/compositor/main/comp_compositor.c b/src/xrt/compositor/main/comp_compositor.c
index b6c4947bf..0e8ed02b7 100644
index 3364aaead..deec90a73 100644
--- a/src/xrt/compositor/main/comp_compositor.c
+++ b/src/xrt/compositor/main/comp_compositor.c
@@ -372,7 +372,7 @@ compositor_request_display_refresh_rate(struct xrt_compositor *xc, float display
@@ -377,7 +377,7 @@ compositor_request_display_refresh_rate(struct xrt_compositor *xc, float display
if (c->target && c->target->request_refresh_rate) {
xrt_result_t result = comp_target_request_refresh_rate(c->target, display_refresh_rate_hz);
// Assume refresh rate change is immediate
@@ -1,4 +1,4 @@
From 8c322edfafa6179875bfe1dca1517c4043f0c5b4 Mon Sep 17 00:00:00 2001
From 4b5685fc3177fd2f54996e0a87c1efe985db9c7b Mon Sep 17 00:00:00 2001
From: Patrick Nicolas <patricknicolas@laposte.net>
Date: Wed, 11 Sep 2024 22:56:29 +0200
Subject: [PATCH 5/9] Replace distortion with foveation
@@ -1,4 +1,4 @@
From b9acd6d83db324c6f31572615fb6738a6f93d63c Mon Sep 17 00:00:00 2001
From 5664ae214c09deb241507526e749f83f3a16298c Mon Sep 17 00:00:00 2001
From: no name <git-am@invalid>
Date: Sun, 28 Sep 2025 11:33:10 +0200
Subject: [PATCH 6/9] d/steamvr_lh: prevent crash on vive pro2/WiVRn
@@ -1,49 +1,27 @@
From 8c6580e84690ffe8f082cdff5ead8443d1f6bf23 Mon Sep 17 00:00:00 2001
From 4fdc8798f4810145c446fe147ae94e4c717b6b28 Mon Sep 17 00:00:00 2001
From: Sapphire <imsapphire0@gmail.com>
Date: Fri, 7 Nov 2025 20:41:16 -0600
Subject: [PATCH 7/9] st/oxr: push XrEventDataInteractionProfileChanged when
profile changes to NULL
---
src/xrt/state_trackers/oxr/actions/oxr_input.c | 15 +++++----------
1 file changed, 5 insertions(+), 10 deletions(-)
src/xrt/state_trackers/oxr/actions/oxr_input.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/src/xrt/state_trackers/oxr/actions/oxr_input.c b/src/xrt/state_trackers/oxr/actions/oxr_input.c
index 349c9adcb..667163142 100644
index 269c6ec62..05a747f74 100644
--- a/src/xrt/state_trackers/oxr/actions/oxr_input.c
+++ b/src/xrt/state_trackers/oxr/actions/oxr_input.c
@@ -1945,26 +1945,21 @@ oxr_session_update_action_bindings(struct oxr_logger *log, struct oxr_session *s
}
}
- /*
- * This code will only send events (and update the bindings) if there
- * is a profile mapped to the subaction path. Meaning it won't update
- * the cache or generate events when a controller goes away, basically
- * latching the interaction profile to the last active device.
- */
+ bool any_profile_changed = false;
@@ -1947,9 +1947,6 @@ session_update_action_bindings(struct oxr_logger *log,
#define POPULATE_PROFILE(X) \
do { \
XrPath path = profiles.X != NULL ? profiles.X->path : XR_NULL_PATH; \
- if (path == XR_NULL_PATH) { \
- break; /* Only update on "active" interaction profiles per sub-action path. */ \
- } \
if (sess->X != path) { \
sess->X = path; \
- oxr_event_push_XrEventDataInteractionProfileChanged(log, sess); \
+ any_profile_changed = true; \
} \
} while (false);
OXR_FOR_EACH_VALID_SUBACTION_PATH(POPULATE_PROFILE)
#undef POPULATE_PROFILE
+ if (any_profile_changed) {
+ oxr_event_push_XrEventDataInteractionProfileChanged(log, sess);
+ }
return oxr_session_success_result(sess);
}
if (action_context->X != path) { \
action_context->X = path; \
interaction_profile_changed = true; \
--
2.53.0
@@ -1,4 +1,4 @@
From 959707499b31f8db80f28492d1bfc01e34b23368 Mon Sep 17 00:00:00 2001
From 025dcad51542cd6c23d9a6ad16cca982bf2fa5ca Mon Sep 17 00:00:00 2001
From: no name <git-am@invalid>
Date: Thu, 15 Jan 2026 12:13:06 +0100
Subject: [PATCH 8/9] Don't get pose data in compositor
@@ -1,4 +1,4 @@
From 14e5d4a2f29b95f0f7933dbf2dde5000c0a98866 Mon Sep 17 00:00:00 2001
From dfacf60061206ca6f41b8bc44e9cd7166230d77e Mon Sep 17 00:00:00 2001
From: no name <git-am@invalid>
Date: Sun, 25 Jan 2026 10:09:10 +0100
Subject: [PATCH 9/9] don't verify GL stuff
@@ -0,0 +1,37 @@
From a9ac675eab72a6ce96adb38215e83f7b3e9b51e7 Mon Sep 17 00:00:00 2001
From: no name <git-am@invalid>
Date: Fri, 20 Mar 2026 16:51:18 +0100
Subject: [PATCH] configure u_git_tag in WiVRn
---
src/xrt/auxiliary/util/CMakeLists.txt | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/src/xrt/auxiliary/util/CMakeLists.txt b/src/xrt/auxiliary/util/CMakeLists.txt
index d45cd60c9..ec0d45434 100644
--- a/src/xrt/auxiliary/util/CMakeLists.txt
+++ b/src/xrt/auxiliary/util/CMakeLists.txt
@@ -10,11 +10,6 @@
# by applications like the OpenXR runtime library.
#
-configure_file(
- "${CMAKE_CURRENT_SOURCE_DIR}/u_git_tag.c.in" "${CMAKE_CURRENT_BINARY_DIR}/u_git_tag.c"
- @ONLY
- )
-
add_library(
aux_util STATIC
u_autoexpgain.c
@@ -118,7 +113,7 @@ add_library(
u_worker.cpp
u_worker.h
u_worker.hpp
- "${CMAKE_CURRENT_BINARY_DIR}/u_git_tag.c"
+ "${U_GIT_TAG_CPP}"
)
target_link_libraries(
aux_util
--
2.53.0
+1
View File
@@ -1,3 +1,4 @@
set(U_GIT_TAG_CPP "${CMAKE_BINARY_DIR}/u_git_tag.cpp")
set(XRT_BUILD_DRIVER_ARDUINO OFF)
set(XRT_BUILD_DRIVER_BLUBUR_S1 OFF)
+2 -2
View File
@@ -487,8 +487,8 @@ VkResult wivrn_comp_target::present(
assert(present_queue != nullptr);
(void)present_queue;
assert(index < cn->image_count);
assert(cn->psc.images[index].status == pseudo_swapchain::status_t::acquired);
assert(index < image_count);
assert(psc.images[index].status == pseudo_swapchain::status_t::acquired);
auto vk = get_vk();
auto res = wivrn_bundle->device.waitForFences(*psc.fence, true, UINT64_MAX);
+36
View File
@@ -0,0 +1,36 @@
#include <cctype>
#include <charconv>
#include <stdint.h>
#include <string_view>
namespace
{
uint16_t version(int digit)
{
std::string_view tag = "@GIT_DESC@";
if (not tag.empty() and tag[0] == 'v')
tag = tag.substr(1);
for (; digit > 0; --digit)
{
while (not tag.empty() and std::isdigit(tag[0]))
tag = tag.substr(1);
if (not tag.empty() and tag[0] == '.')
tag = tag.substr(1);
}
tag = tag.substr(0, tag.find('.'));
uint16_t val = 0;
// We don't care if parsing fail, return 0
std::from_chars(tag.begin(), tag.end(), val);
return val;
}
} // namespace
extern "C"
{
extern const char u_git_tag[] = "@GIT_DESC@";
extern const uint16_t u_version_major = version(0);
extern const uint16_t u_version_minor = version(1);
extern const uint16_t u_version_patch = version(2);
extern const char u_runtime_description[] = "WiVRn";
}