Commit graph

5597 commits

Author SHA1 Message Date
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
Mario Kleiner 0116a76db5 d/vive: Add Vive Wand controller name string for the HTC Vive Pro Eye.
Behave like other Wands, just a different name string.

Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
2023-04-14 10:48:39 +00:00
Jakob Bornecrantz 6fc7603e55 doc: Document !1748 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz 86262e8b4e a/vk: Remove global command pool 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz e9475b1313 c/main: Use cmd helpers for main submission 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz 231a743896 c/main: Use cmd pool helpers in peek code 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz 185bc2bc3c c/main: Use cmd pool helpers in mirror window code 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz 5ef2b647f1 c/main: Use cmd pool helpers in layer render 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz 1ddfcaa5ab c/client: Use cmd pool helpers 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz d1906d1cf8 c/util: Use cmd pool helpers in swapchain code 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz 197461b4cd c/render: Refactor close loops [NFC] 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz 6598760522 c/render: Put distortion image functions in own file 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz f536ec2009 c/render: Use cmd pool helpers in init code 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz e5fed9c3be c/render: Improve error handling 2023-04-14 02:34:49 +01:00
Jakob Bornecrantz 68b8a2f371 a/vk: Add command pool helpers 2023-04-14 02:34:49 +01:00
Moshi Turner 4d3c1cf7c5 t/common: Parse upside-down DepthAI device in North Star builder 2023-04-13 11:50:38 +00:00
Moshi Turner bdc33510a1 h/mercury: Dump camera calibration if debugging 2023-04-13 11:50:38 +00:00
utzcoz 667a0404c2 a/util: Remove unused headers for u_var.cpp 2023-04-13 06:41:06 +00:00
Moshi Turner ec59e97bda st/gui: Use IMU in EuRoC recorder scene 2023-04-12 16:43:20 -05:00
Moshi Turner c05c5d5c2e st/gui: Add EuRoC recorder for DepthAI cameras 2023-04-12 12:19:13 +00:00
Moshi Turner 53e738a093 d/dai: Add manual exposure controls 2023-04-12 12:11:06 +00:00
Jakob Bornecrantz ee0dad22d5 c/main: Tidy readback code [NFC] 2023-04-12 12:49:24 +01:00
Moshi Turner f2bea2c7c6 d/ns; a/util: Remove old name from Moshi's distortion correction method
I don't hate my old name that much, but this is my last chance to change it before there's some "moshi-style" North Stars floating around.
2023-04-11 23:45:23 -05:00
Moshi Turner 19e0af55d2 c/main: Bounce readback images off temporary image
Most NVidia graphics cards don't support blitting straight from device memory to host memory, but all GPUs support doing it this way.
2023-04-11 22:27:36 -05:00
Moshi Turner 51ff80e802 st/gui: Lazily create debug sinks so that they can be created at any time
Useful for deferred-creation compositors, and for repositories submoduling Monado.
2023-04-11 19:50:41 -05:00
utzcoz 39d701a30c t/common: Fix small typo for target_builder_simulated.c's comment [NFC] 2023-04-11 12:00:01 +00:00
utzcoz 5565564e70 gradle: Fix building with JDK11+
1. Bump Kotlin version to 1.7.10.
2. Bump Hilt version to 2.45.
3. Add implementation of lifecycle-viewmodel-ktx dependency explicitly
   to fix duplicate class error.

Signed-off-by: utzcoz <utzcoz@outlook.com>
2023-04-11 11:43:57 +00:00
utzcoz 08831237f5 gradle: Migrate compileSdkVersion to compileSdk
Signed-off-by: utzcoz <utzcoz@outlook.com>
2023-04-11 11:43:57 +00:00
utzcoz 8a062e9836 .gitignore: Ignore .hprof files
Signed-off-by: utzcoz <utzcoz@outlook.com>
2023-04-11 11:43:57 +00:00
Christoph Haag c248670f2f d/survive: Add vive ipd range 2023-04-11 11:42:21 +00:00
Ryan Pavlik 0efb008492 ci: Adjust conditions to fix fork push builds. 2023-04-10 15:21:38 -05:00
Ryan Pavlik af29da2545 gradle: Use static C++ runtime library by default when building Monado, for compatibility.
We do not export any C++ symbols.

Added property to allow selection of shared C++ standard lib.
2023-04-10 14:11:41 -05:00
Ryan Pavlik 788973926a gradle: Fix warning related to dagger 2023-04-10 14:11:41 -05:00
Ryan Pavlik 8bc8abe904 gradle: Fix parsing OpenXR version 2023-04-10 14:11:41 -05:00
Ryan Pavlik 048552f914 gradle: Adjust where we generate files to 2023-04-10 14:11:41 -05:00
Ryan Pavlik 8b50c5cb9e gradle: Do not need the CDDL anymore because Dagger changed its deps 2023-04-10 14:11:41 -05:00
Ryan Pavlik 4369640ecc android: Clean up manifest and silence warnings 2023-04-10 14:11:41 -05:00
Ryan Pavlik 35b1bc063d gradle: Update dependencies further and fix conflicts 2023-04-10 14:11:41 -05:00
utzcoz 0cf9ee9ee5 clang-tidy: Enable -misc-unused-using-decls check
It is supported at least from clang-format-8:
https://releases.llvm.org/8.0.0/tools/clang/tools/extra/docs/clang-tidy/checks/misc-unused-using-decls.html
2023-04-10 11:06:23 +00:00
Jakob Bornecrantz cad9e37689 doc: Document !1766 2023-04-09 14:10:47 +01:00
Jakob Bornecrantz 5f1b54bcd5 a/vk: Add blit and copy helpers 2023-04-09 14:04:53 +01:00
Jakob Bornecrantz c0287b690b a/vk: Add command helpers 2023-04-09 12:01:27 +01:00
Jakob Bornecrantz 14f15284a1 a/vk: Update comments for command buffer writers 2023-04-08 00:03:20 +01:00
Jakob Bornecrantz f0cff9db0c doc: Document !1763 2023-04-07 21:44:22 +01:00
Jakob Bornecrantz 585e23054d a/vk: Use helper define in vk_csci_get_image_usage_flags 2023-04-07 21:44:22 +01:00