Commit graph

4722 commits

Author SHA1 Message Date
bjorn 217c9749dc Changelog; 2022-07-01 22:01:32 +00:00
bjorn 128ea42915 c/render: inline vk_command_buffer helper;
It's not really abstracting much anymore, and makes it more difficult to
see what's going on.
2022-07-01 22:01:32 +00:00
bjorn 4c09d20f80 c/render: render_resources has its own command pool;
Currently, there is a single command pool in the vk bundle, shared by
everyone.  Since command pools (and command buffers allocated from those
pools) can only be used on one thread at a time, this requires locking.
However, the main point of having these annoying command pool things in
the first place is that you can use one for each thread/lifetime/area in
the app and avoid the overhead of the locks (both computational and
cognitive).

In this change I have given the rendering bits of the compositor its own
command pool.  Instead of allocating and freeing a command buffer every
frame, a single command buffer is allocated from the pool during
initialization, and the pool is reset at the beginning of each frame.
Normally, multiple pools would need to be used, but this is not
necessary in monado because frames are serialized. The `TRANSIENT` and
`ONE_TIME_SUBMIT` flags have been added, which can allow for some driver
optimizations.  The render code no longer takes out the command pool
mutex.  The shared command pool is still there for a few remaining
places where vulkan work needs to be done outside the compositor.

I used the command buffer vulkan helpers when possible, but I would
maybe propose the idea of removing them, since they aren't really
wrapping much at this point.  The `C` macro helps a lot and it's a bit
easier to see the Vulkan details in front of you instead of needing to
switch back and forth between the helper.

Later, I think it would be cool to apply and document some constraints
like "the queue is only accessed in functions XYZ, the render_resources
command pool must only be accessed in layer_commit from 1 thread" etc.
2022-07-01 22:01:32 +00:00
bjorn 24c9dabfbb aux/vk: Add vkResetCommandPool; 2022-07-01 22:01:32 +00:00
Ryan Pavlik 0496ba9c5c aux/vk: Add additional include dirs conditionally. 2022-07-01 21:57:07 +00:00
Ryan Pavlik 3689eca3ce cmake: Update presets to use provided build types and not hardcode compiler flags.
The hardcoded compiler flags meant some of these were broken on MSVC.
2022-07-01 21:51:36 +00:00
bjorn 0ff4104b38 Add changelog; 2022-07-01 12:40:09 -07:00
bjorn a4e5a2d027 Support cubemap swapchains; 2022-07-01 12:23:53 -07:00
Moses Turner e552ef6bf3 t/common: Better error-checking in lighthouse builder 2022-06-30 15:20:46 +01:00
Moses Turner 567304374d d/v4l2: Factor out format setup so we can catch errors in stream_start 2022-06-30 15:19:51 +01:00
Jakob Bornecrantz 2cbad30823 u/pacing: Introduce a app pacing factory 2022-06-27 19:09:46 +01:00
Jakob Bornecrantz 6e2644dea7 u/pacing: Tidy comments 2022-06-27 19:09:46 +01:00
Jakob Bornecrantz 0fb155b886 c/multi: Include interface header 2022-06-27 19:09:46 +01:00
Jakob Bornecrantz 23aca9c0b9 c/multi: Document multi_system_compositor 2022-06-27 18:35:40 +01:00
Jakob Bornecrantz 202f37be63 t/common: Include config build for null compositor 2022-06-27 18:35:40 +01:00
Ryan Pavlik 404c4b62a2 doc: Document Android-related MRs 2022-06-27 10:00:06 -05:00
Ryan Pavlik b4aed1309c ci: Move default versions from install-android-sdk to the config.yml 2022-06-27 10:00:06 -05:00
Ryan Pavlik 6028c81796 ci: Bump versions of tools and sdks for Android 2022-06-27 10:00:06 -05:00
utzcoz 10b5df277d gradle: Bump Gradle to 7.4.2
Signed-off-by: utzcoz <utzcoz@outlook.com>
2022-06-27 10:00:01 -05:00
utzcoz 34c97c48ef ipc,t/oxr_android: Add FLAG_IMMUTABLE for PendingIntent from S+
Signed-off-by: utzcoz <utzcoz@outlook.com>
2022-06-27 09:59:27 -05:00
Ryan Pavlik 62c87d27d6 android: Request new android.permission.HIGH_SAMPLING_RATE_SENSORS 2022-06-25 09:59:37 +08:00
Ryan Pavlik 466706e37a gradle: Upgrade some plugins. 2022-06-25 09:59:37 +08:00
Ryan Pavlik cec89ae751 targets: Update manifests for Android 12 2022-06-25 09:59:37 +08:00
utzcoz cf3e79a083 gradle: Upgrade Gradle to 7.4.1
Signed-off-by: utzcoz <utzcoz@outlook.com>
2022-06-25 09:59:37 +08:00
Ryan Pavlik e1a0486f30 gradle: Update some deps slightly to cope with gradle 7 2022-06-25 09:59:37 +08:00
Ryan Pavlik 98f430f6f7 gradle: More dependency updates. 2022-06-25 09:59:37 +08:00
Moses Turner fb3c3db34a doc: Document monado!1296 2022-06-24 01:58:51 +01:00
Moses Turner 4aaa61350b t/common: Add lighthouse builder 2022-06-24 01:58:51 +01:00
Moses Turner bd421e683c d/vive: Handle not-found devices correctly 2022-06-24 01:58:51 +01:00
Moses Turner 29cd525a3b d/vive: Prepare for lighthouse builder 2022-06-24 01:54:45 +01:00
Moses Turner 766f1b94e9 d/survive: Remove lots of cruft and prepare for Lighthouse builder 2022-06-24 01:54:45 +01:00
Moses Turner adadf6a2c2 t/common: Remove (sur)vive from legacy builder 2022-06-24 01:54:45 +01:00
Moses Turner 19958b4d77 d/ht: Remove cruft for Index 2022-06-24 01:54:45 +01:00
Moses Turner 00b6dd35ec d/survive: Don't create hand-tracker ourselves 2022-06-24 01:54:45 +01:00
Moses Turner a853022a66 d/vive: Don't create the hand-tracker ourselves 2022-06-24 01:54:45 +01:00
Moses Turner 6b63d473c6 t/common: Switch target_builder_legacy to u_system_devices_get_ht_device 2022-06-24 01:54:45 +01:00
Moses Turner a67d2fc28b a/util: Add u_system_devices_get_ht_device 2022-06-24 01:54:45 +01:00
Moses Turner 307e3ca1dc h/old_rgb: Fix regressions 2022-06-24 01:54:45 +01:00
Moses Turner 0e50364be6 d/ht: Don't drop algorithm_choice on the floor 2022-06-24 01:54:45 +01:00
Jakob Bornecrantz 218fbeae4e a/vk: Free "unused" AHardwareBuffer
It was only used for getting the format, free it until the function can
be completely rewritten to use it instead.
2022-06-21 20:47:04 +00:00
Jakob Bornecrantz 2c688a2d08 a/vk: Tidy return variable name 2022-06-21 20:47:04 +00:00
Jakob Bornecrantz 13504a29af a/vk: Return an error if ahardwarebuffer_image_allocate fails 2022-06-21 20:47:04 +00:00
Moses Turner 6f21741c51 xrt: Fixup - rename *all* of the relevant hand-tracking structs 2022-06-21 21:18:41 +01:00
Moses Turner 1718d01fb1 xrt: Rename some hand-tracking structs and document them better 2022-06-21 20:37:08 +01:00
Moses Turner 9063c7dd82 doc: Document !1381 2022-06-20 16:33:48 +01:00
Moses Turner 53e719e0e8 doc: Add some notes about Mercury hand tracking 2022-06-20 16:33:48 +01:00
Moses Turner b4a29e8b29 tests: Add case for Levenberg-Marquardt optimizer 2022-06-20 16:33:48 +01:00
Moses Turner 73dbc712ab h/mercury: Add Levenberg-Marquardt optimizer, and lots of fixes!
Co-authored-by: Charlton Rodda <charlton.rodda@collabora.com>
Co-authored-by: Ryan Pavlik <ryan.pavlik@collabora.com>
2022-06-20 16:33:48 +01:00
Moses Turner 8040224b39 xrt: add hand_tracking_image_boundary_info 2022-06-20 16:33:48 +01:00
Moses Turner db85ea2df5 external: Add tinyceres 2022-06-20 14:36:20 +01:00