Monado merge requestshttps://gitlab.freedesktop.org/monado/monado/-/merge_requests2024-03-17T03:54:05Zhttps://gitlab.freedesktop.org/monado/monado/-/merge_requests/2163Adds support for face-tracking / XR_HTC_facial_tracking xrt-devices2024-03-17T03:54:05ZkorejanAdds support for face-tracking / XR_HTC_facial_tracking xrt-devices* Adds framework for face-tracking xrt-devices
* Adds support for XR_HTC_facial_tracking xrt-devices* Adds framework for face-tracking xrt-devices
* Adds support for XR_HTC_facial_tracking xrt-deviceshttps://gitlab.freedesktop.org/monado/monado/-/merge_requests/2150Rename Nreal Air driver to Xreal Air and support two newer models2024-03-14T08:38:52ZTobias FrischRename Nreal Air driver to Xreal Air and support two newer models- I've renamed the driver from Nreal to Xreal since the company rebranded itself some time ago (as mentioned here: #330).
- I've adjusted the naming to match the driver for the Xreal Light (here: !2145).
- I've added the product IDs from...- I've renamed the driver from Nreal to Xreal since the company rebranded itself some time ago (as mentioned here: #330).
- I've adjusted the naming to match the driver for the Xreal Light (here: !2145).
- I've added the product IDs from the Xreal Air 2 and the Xreal Air 2 Pro. They should work with the same driver theoretically.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2164File mode2024-03-09T01:12:54ZRylie PavlikFile modeBug fix extracted from !2086Bug fix extracted from !2086https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2116xrt: prevent systemd from starting Monado quickly2024-01-15T16:31:05ZSefa Eyeoglucontact@scrumplex.netxrt: prevent systemd from starting Monado quicklyIf an OpenXR client starts Monado using socket activation,
but Monado crashes during its startup,
systemd will try to start the service for each subsequent IPC message,
which causes both units to enter a failed state.
By enabling [`Flus...If an OpenXR client starts Monado using socket activation,
but Monado crashes during its startup,
systemd will try to start the service for each subsequent IPC message,
which causes both units to enter a failed state.
By enabling [`FlushPending`](https://www.freedesktop.org/software/systemd/man/latest/systemd.socket.html#FlushPending=),
systemd will flush pending messages and close the connection to the IPC client,
preventing restarts in quick succession.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2110st/gui: Remote add infinitely fast trigger finger2024-01-08T18:57:19ZJakob Bornecrantzst/gui: Remote add infinitely fast trigger fingerBuilds on !2109.
Helps working around CTS issue.Builds on !2109.
Helps working around CTS issue.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2113Let sub-classed targets override extents2024-01-08T17:00:44ZJakob BornecrantzLet sub-classed targets override extentsThe big win here is that targets no longer writes the `preferred_[width|height]` on the compositors settings struct. And this moves us closer to not using `comp_compositor` or `comp_settings` in the targets which means they can be refact...The big win here is that targets no longer writes the `preferred_[width|height]` on the compositors settings struct. And this moves us closer to not using `comp_compositor` or `comp_settings` in the targets which means they can be refactored out of `main` and put into `util`, lettings us reuse them, and even have multiple ones active at the same time.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2111ext/openxr: Bump OpenXR headers to 1.0.332024-01-08T05:39:05Zutzcozext/openxr: Bump OpenXR headers to 1.0.331. Download and unzip from
https://github.com/KhronosGroup/OpenXR-SDK/releases/tag/release-1.0.33.
2. Copy all header files in include directory to
src/external/openxr_includes/openxr.1. Download and unzip from
https://github.com/KhronosGroup/OpenXR-SDK/releases/tag/release-1.0.33.
2. Copy all header files in include directory to
src/external/openxr_includes/openxr.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/793d/vive: Small improvements to IMU and driver code2024-01-07T19:55:08ZChristoph Haagd/vive: Small improvements to IMU and driver codeThis MR used to be titled "d/vive: Apply gyro bias in zxy order" changed to bring in changes that was improvements in general to the driver. Old message below.
---
This is RFC because I have not tested it on any other device than my Va...This MR used to be titled "d/vive: Apply gyro bias in zxy order" changed to bring in changes that was improvements in general to the driver. Old message below.
---
This is RFC because I have not tested it on any other device than my Valve Index, on which it stops heavy drifting.
My Valve Index heavily drifts with the original order while resting.
```
gyro without bias x = 0.023702 y = -0.001598 z = 0.010919
bias x = 0.008667 y = -0.009314 z = 0.025930
```
Acceleration bias does NOT seem to follow that scheme and applying it
in zxy order causes visually worse tracking behavior.
```
acc without bias x = -9.753767 y = -0.019156 z = -0.543914
bias x = 0.059932 y = -0.090968 z = 0.021342
```Christoph HaagChristoph Haaghttps://gitlab.freedesktop.org/monado/monado/-/merge_requests/2090d/steamvr_lh: simplify coordinate space conversion2024-01-05T00:54:43Zrcelyted/steamvr_lh: simplify coordinate space conversionI rewrote `Device::update_pose()` to make use of `math_pose_transform()` instead of doing the three operations separately, making it easier to understand what the code is actually doing. Additionally, `chaperone_center` and `chaperone_ya...I rewrote `Device::update_pose()` to make use of `math_pose_transform()` instead of doing the three operations separately, making it easier to understand what the code is actually doing. Additionally, `chaperone_center` and `chaperone_yaw` have been unified into an `xrt_pose` for consistency.
I have confirmed the output is identical (± floating point rounding error) to the old function.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2068Optimize FPS calculation using precomputed frame timings2024-01-05T00:15:06ZMeng JiaoOptimize FPS calculation using precomputed frame timingsThis commit streamlines the FPS calculation within the frame times widget by utilizing the precomputed `timings_ms` array that already contains the durations between frames in milliseconds. By summing up these precomputed timings, we avo...This commit streamlines the FPS calculation within the frame times widget by utilizing the precomputed `timings_ms` array that already contains the durations between frames in milliseconds. By summing up these precomputed timings, we avoid redundant computation of frame durations from the `times_ns` timestamps.
The optimized approach calculates the total frame time directly in milliseconds, determines the average frame time, and then computes the FPS by dividing 1000 ms by the average frame time in milliseconds. This change not only improves the efficiency of the code but also simplifies the logic for calculating the average FPS.
Refactoring:
- Use `timings_ms` instead of recomputing frame durations from `times_ns`.
- Calculate `total_ms` and `avg_frametime_ms` within the FPS update conditional.
- Adjust FPS calculation to `1000.f / avg_frametime_ms`.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/1988d/wmr: Add WMR_DISPLAY_VIEW_OFFSET env var2024-01-04T23:47:58ZChristoph Haagd/wmr: Add WMR_DISPLAY_VIEW_OFFSET env varhttps://gitlab.freedesktop.org/monado/monado/-/merge_requests/2109Fix crash in CTS on number of bindings2024-01-04T22:32:22ZJakob BornecrantzFix crash in CTS on number of bindingsThe CTS has more then 16. The limit is just during binding, not actually after.The CTS has more then 16. The limit is just during binding, not actually after.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/1104More pacing improvements and tests2024-01-04T20:30:45ZRylie PavlikMore pacing improvements and testsEssentially no functional change. But, slightly better API, and now we have tests!Essentially no functional change. But, slightly better API, and now we have tests!Jakob BornecrantzJakob Bornecrantzhttps://gitlab.freedesktop.org/monado/monado/-/merge_requests/2108Better compositor tracking and live statistics2024-01-04T20:17:23ZJakob BornecrantzBetter compositor tracking and live statisticsBuilds on !2101
If you use the fake compositor pacer and set `U_PACING_LIVE_STATS=true` the pacing code will now generate lives statistics about every 1024 frames. It looks something like the below. This MR also include improvements in ...Builds on !2101
If you use the fake compositor pacer and set `U_PACING_LIVE_STATS=true` the pacing code will now generate lives statistics about every 1024 frames. It looks something like the below. This MR also include improvements in frame tracking so we can see the overhead of the kernel and any delays before the GPU picks up the work we scheduled. If you see the first message that the worst `gpu_delay` is `0.963ms`, and it is a major contributor to the frame taking a long time.
```txt
INFO [print_and_reset] Compositor frame timing:
name median mean worst
cpu 0.008ms 0.007ms 0.014ms
draw 0.107ms 0.108ms 0.385ms
submit 0.049ms 0.049ms 0.077ms
gpu 0.175ms 0.180ms 0.386ms
gpu_delay 0.089ms 0.089ms 0.963ms
total_frame 0.380ms 0.388ms 1.509ms
WARN [wait_for_scheduled_free] 277549598.581ms: Dropping old missed frame in favour for completed new frame
INFO [print_and_reset] Compositor frame timing:
name median mean worst
cpu 0.008ms 0.007ms 0.013ms
draw 0.108ms 0.107ms 0.166ms
submit 0.049ms 0.050ms 0.118ms
gpu 0.175ms 0.175ms 0.180ms
gpu_delay 0.092ms 0.092ms 0.196ms
total_frame 0.385ms 0.384ms 0.499ms
```
A really large values looks like this:
```txt
name median mean worst
cpu 0.008ms 79'650.000ms 0.013ms
draw 0.105ms 1'096'130.000ms 0.166ms
submit 0.052ms 509'260.000ms 0.118ms
gpu 0.174ms 1'745'250.000ms 0.180ms
gpu_delay 0.089ms 903'380.000ms 0.196ms
total_frame 0.382ms 3'840'680.000ms 0.499ms
```https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2042Avoid swapchain leak on Android2024-01-04T20:16:45ZRylie PavlikAvoid swapchain leak on AndroidThe import does not consume them.
Revised version of !2021 - we unref right away now, and have a define for if we don't need to.
I dropped the last commit because it seemed redundant now.The import does not consume them.
Revised version of !2021 - we unref right away now, and have a define for if we don't need to.
I dropped the last commit because it seemed redundant now.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2106a/math: Refactor m_clock_offset_a2b2024-01-04T16:39:13ZJan Schmidta/math: Refactor m_clock_offset_a2bAvoid limited precision float operations on large 64-bit
integers. The clock averaging was basically not working
once the clock values got largeAvoid limited precision float operations on large 64-bit
integers. The clock averaging was basically not working
once the clock values got largehttps://gitlab.freedesktop.org/monado/monado/-/merge_requests/2103Preview window goes wrooom!2024-01-04T16:31:38ZJakob BornecrantzPreview window goes wrooom!This improves the performance of the mirror/preview in the debug UI. In the past the mirror/preview was powered by doing a readback to host memory from the GPU, then uploading it in OpenGL to the GPU in the UI part of the code. We skip t...This improves the performance of the mirror/preview in the debug UI. In the past the mirror/preview was powered by doing a readback to host memory from the GPU, then uploading it in OpenGL to the GPU in the UI part of the code. We skip the readback/upload completely now and share the memory directly. Improving performance quite a bit.
Builds on !2100 and !2101.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2039Device function helpers.2024-01-04T13:07:41ZJakob BornecrantzDevice function helpers.Builds on !2038.Builds on !2038.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2101c/render: Render arguments refactor2024-01-04T12:09:49ZJakob Bornecrantzc/render: Render arguments refactorBuilds on !2100.Builds on !2100.https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2099libmonado: Add device property getters2024-01-04T11:16:05ZJakob Bornecrantzlibmonado: Add device property gettersAdd new device properties, remove device ID it's deprecated.Add new device properties, remove device ID it's deprecated.