Commit graph

5741 commits

Author SHA1 Message Date
Jan Schmidt ed54b7899c d/wmr: Don't wait forever for HMD firmware
Add a 100ms timeout for firmware reads from the HMD,
and error out if it takes longer. Fixes problems
sometimes waiting forever on my G2 when it gets
into a bad state.
2023-05-01 13:51:44 +01:00
Jan Schmidt 7b4fffed8f d/wmr: Improve readability in the camera source 2023-05-01 13:51:44 +01:00
Jan Schmidt e9c977243f u/logging: Add hexdump logging method
Add macros for logging hexdumps of memory blocks to help
with driver development. Only macros for trace and debug
level logging are provided, as noone should be logging
hexdumps except for development.
2023-05-01 13:51:44 +01:00
utzcoz 4f171b3d55 ext/openxr: Update headers to 1.0.27
Signed-off-by: utzcoz <utzcoz@outlook.com>
2023-04-27 21:48:50 +08:00
Jakob Bornecrantz 5197b4a42f d/vive: Add a slider to adjust all tracked pose timestamps 2023-04-26 22:17:36 +01:00
Jakob Bornecrantz ce3c5d59fb d/wmr: Add a slider to adjust all tracked pose timestamps 2023-04-26 22:17:36 +01:00
Jakob Bornecrantz 9d8668a0a6 cmake: Remove _SLAM suffixes on KIMERA and BASALT have defines 2023-04-26 21:39:16 +01:00
Jakob Bornecrantz 99c1742c82 ext/slam: Use LDFLAGS instead of libraries
This lets us avoid LIBRARY_PATH in order to build Monado.
2023-04-26 21:39:16 +01:00
Ryan Pavlik c924157c59 a/android: Only look up the standardized intent to find our own package.
Should allow a constrained query manifest in client apps.
2023-04-25 10:40:58 -05:00
Ryan Pavlik f57bc4a849 android-jni-wrap: Update to add more things 2023-04-24 11:43:30 -05:00
Christoph Haag aa052046a8 cmake: Delete active_runtime.json if it already exists 2023-04-24 13:57:00 +00:00
utzcoz 0f2699b02f ci: Install sdl2 with vulkan feature
We need to update MONADO_WIN_BASE_TAG and MONADO_WIN_MAIN_TAG to trigger
container rebuilding.
2023-04-24 03:27:01 +00:00
utzcoz 6032b4dc8b vcpkg: Enable vulkan feature for sdl2
The comp_window_peek needs sdl2 with Vulkan supporting, and normal sdl2
installation doesn't support Vulkan. So we need to install Vulkan
feature of sdl2 explicitly to let sdl2 work with Vulkan, and let
comp_window_peek works on Windows.
2023-04-24 03:27:01 +00:00
Jakob Bornecrantz c0d242e1ed a/vk: Fix doccomment style [NFC] 2023-04-21 14:28:18 +01:00
Jakob Bornecrantz 17ea4a73eb a/vk: Mark unexported function as static [NFC] 2023-04-21 14:28:18 +01:00
Jakob Bornecrantz c7fa7fe701 a/vk: Loop over all optional extensions, not just the first
This caused the event thread to not start
because the needed extensions where not enabled.
2023-04-21 14:27:33 +01:00
Jakob Bornecrantz 05792ff150 st/oxr: Refactor OXR_NO_PRINTING env vars 2023-04-18 22:28:53 +01:00
Jakob Bornecrantz fa0b3ad73c st/oxr: Refactor logging functions and use OutputDebugStringA on Windows
The OXR logging functions are not called during normal opperation so it's okay
to always copy into a full buffer.
2023-04-18 22:28:53 +01:00
Jarvis Huang 0d31791092 comp/android: Refine surface creation flow
Reuse MonadoView when "Display over other apps" is enabled. Move surface
creation logic to compositor for consistency. With this approach, compositor
implementer controls the way surface is created.
2023-04-18 16:24:35 -05:00
Jarvis Huang cf7e44b710 aux/android: Refactor MonadoView 2023-04-18 16:22:42 -05:00
Jarvis Huang 7c02d466e2 externl: Update android-jni-wrap 2023-04-18 16:22:42 -05:00
Jarvis Huang d60db29295 aux/android: Refactor SystemUiController 2023-04-18 16:22:42 -05:00
Jakob Bornecrantz 255a74a8e8 doc: Document !1743 2023-04-18 14:31:55 +01:00
Jakob Bornecrantz 7147e47508 c/client: Implement excplicit transitions in Vulkan and D3D12 2023-04-18 14:31:55 +01:00
Jakob Bornecrantz 45fe1d6ed0 st/oxr: Refactor swapchains to use explicit transitions 2023-04-18 14:31:55 +01:00
Jakob Bornecrantz 6415480f1c st/oxr: Tidy includes [NFC] 2023-04-18 14:21:10 +01:00
Jakob Bornecrantz b49cd74114 st/oxr: Rename and document common swapchain creation function [NFC] 2023-04-18 14:21:10 +01:00
Jakob Bornecrantz 9055b9d2ec st/oxr: Remove unneeded prefixes on functions [NFC] 2023-04-18 14:21:10 +01:00
Jakob Bornecrantz 52f790289d st/oxr: Swapchain destroy was the same for all APIs 2023-04-18 14:21:10 +01:00
Jakob Bornecrantz a56caf762e st/oxr: Refactor swapchain functions a bit 2023-04-18 14:21:10 +01:00
Jakob Bornecrantz 505e4e8c2f c/client: Refactor image barrier submission into a helper function 2023-04-18 14:21:10 +01:00
Jakob Bornecrantz 0d21b73b05 c/client: Implement transition image stubs 2023-04-18 14:21:10 +01:00
Jakob Bornecrantz b7362f27e6 xrt: Add image transition inteface 2023-04-18 14:21:10 +01:00
Ryan Pavlik 52d76414c0 contributing: Mention how to run spotless. 2023-04-17 10:58:38 -05:00
utzcoz 498965c1d4 ci: Add spotlessCheck for Android building
Signed-off-by: utzcoz <utzcoz@outlook.com>
2023-04-17 10:58:38 -05:00
utzcoz 06b2ae737b gradle: Enable spotless for Gradle, Markdown and gitignore files
Signed-off-by: utzcoz <utzcoz@outlook.com>
2023-04-17 10:58:38 -05:00
Ryan Pavlik 9840730169 ipc/android: Run spotlessApply to format Java and Kotlin code 2023-04-17 10:58:38 -05:00
Ryan Pavlik fc3af6f711 a/android: Run spotlessApply to format Java and Kotlin code 2023-04-17 10:58:38 -05:00
utzcoz b5b0c30936 t/android: Run spotlessApply to format Java and Kotlin code
Signed-off-by: utzcoz <utzcoz@outlook.com>
2023-04-17 10:58:38 -05:00
utzcoz 8e93bbde4b gradle: Integrate spotless to format Java and Kotlin code
See https://github.com/diffplug/spotless.

Signed-off-by: utzcoz <utzcoz@outlook.com>
2023-04-17 10:58:38 -05:00
Jakob Bornecrantz e3d345d428 ci: Refactor paths, and only build containers for CI path changes 2023-04-15 18:58:21 +01:00
utzcoz c8c5d6444e gradle: Remove redundant dependency of lifecycle-viewmodel
Signed-off-by: utzcoz <utzcoz@outlook.com>
2023-04-15 16:20:50 +00:00
Jakob Bornecrantz b63d3bd6d6 ci: Don't build outside of Monado 2023-04-15 16:51:02 +01:00
Jakob Bornecrantz 9cbc815fbc ci: No manual run of containers 2023-04-15 02:00:14 +01:00
Mario Kleiner ff9ad4016f c/multi: Refine some logging messages a bit.
Add some timestamps and extra logging to the frame scheduling code.

Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
2023-04-15 00:43:20 +00:00
Mario Kleiner ae2e7405dd c/multi: Move log_frame_time_diff() to avoid false late frame reports.
In its original call location, this diagnostic/warning function gets
called for each composition cycle even for client frames which have
not yet been delivered for display, because the frames target display
time "XrFrameEndInfo frameEndInfo.displayTime" (as provided by the
OpenXR client) has not been reached yet. Iow. if a OpenXR client
specifies a target frameEndInfo.displayTime in the future, to request
frame presentation in the future, this will cause a flood of false
"Frame late ..." messages by the compositor, despite nothing being
wrong with the timing, until the frame is actually delivered.

E.g., if frameEndInfo.displayTime is 1 second in the future, we'll
get this for each client xrEndFrame() invocation:

WARN [log_frame_time_diff] Frame late by 11.11ms!
WARN [log_frame_time_diff] Frame late by 22.22ms!
... another 87 like these ...
WARN [log_frame_time_diff] Frame late by 988.43ms!

I think what we want is to only check client frames that are actually
delivered the first time by multi_compositor_deliver_any_frames() for
initial display in the current compositor work cycle, and then report
if this first frame display onset was not on or close to the OpenXR
client requested frameEndInfo.displayTime, but too early or too late,
in violation of the clients wishes.

Moving the call check and call of log_frame_time_diff() achieves this
and gives meaningful debug output.

Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
2023-04-15 00:43:20 +00:00
Mario Kleiner 1c96ee619d u/metrics: Add option to fflush after writing each metrics record.
This allows to use the metrics logging in "streaming mode" where
records are written out with low delay, e.g., into a Unix fifo
file / pipe for live consumption by some tracing or recording
application.

XRT_METRICS_EARLY_FLUSH=true enables this "streaming mode".

Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
2023-04-15 00:32:22 +00:00
Jakob Bornecrantz d7f229959a ci: Try to fix CI 2023-04-15 01:28:50 +01:00
Ryan Pavlik 1bc692116f ci: Adjust rules for deciding whether to build.
Inspired by the Mesa equivalent.
2023-04-14 16:50:18 -05:00
Mario Kleiner 9e647f9a46 d/vive: Parse/Recognize HTC Vive Pro Eye HMD headphone audio buttons.
Does not do anything yet within Monado, but documents how to parse
button state of left headphone volume up/down buttons and right
headphone microphone mute button.

Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
2023-04-14 10:48:39 +00:00