Commit graph

3987 commits

Author SHA1 Message Date
Mateo de Mayo c9f7184d64 t/slam: Implement timing and trajectory error UI graphs 2022-03-14 23:42:13 +00:00
Mateo de Mayo af2dde11c3 misc: Fix some release build warnings and minor changes
- Add CMakeUserPresets.json to .gitignore
- Fix DASSERTs warning for release builds
- Do not use one euro filter with invalid poses
- Other NFC style changes
2022-03-14 23:42:13 +00:00
Mateo de Mayo e889ee7562 d/euroc: Implement ground truth trajectory load 2022-03-14 23:42:13 +00:00
Mateo de Mayo 71694b80fd d/euroc: Refactor player to stream samples more like a real device
Splits the image and IMU producers into their own threads.
2022-03-14 23:42:13 +00:00
Mateo de Mayo 1dbda3d8c8 t/euroc: Tie CSV file opening to recorder lifecycle
This is a better way of handling writing small but high frequency data
like IMU samples so as to avoid continuous opening and closing of a file.
2022-03-14 23:42:13 +00:00
Mateo de Mayo 2d9c1b2b11 external: Update slam_tracker 2.0.0 with support for timing
Adds pose extension functionality with a timing pose extension that
allows SLAM/VIO systems to report internal timestamps for performance
measurement.
2022-03-14 23:42:13 +00:00
Mateo de Mayo 147d4c5d26 xrt: Add groundtruth sink to xrt_slam_sinks 2022-03-14 23:42:13 +00:00
Mateo de Mayo 88bd7a669d xrt: Add pose sink interface 2022-03-14 23:42:13 +00:00
Jakob Bornecrantz 2f31b2e5b0 doc: Update Vulkan extensions table 2022-03-14 19:53:05 +00:00
Jakob Bornecrantz cbdeea94e0 doc: Document !1164 2022-03-14 19:53:05 +00:00
Jakob Bornecrantz c766411b50 c/client: Impelement xrt_compositor_semaphore interfaces 2022-03-14 19:53:05 +00:00
Jakob Bornecrantz ef373662f2 ipc: Impelement xrt_compositor_semaphore interfaces 2022-03-14 19:53:05 +00:00
Jakob Bornecrantz ca7526a3e2 c/multi: Impelement xrt_compositor_semaphore interfaces 2022-03-14 19:53:05 +00:00
Jakob Bornecrantz 8a9a8aeeba c/util: Impelement xrt_compositor_semaphore interfaces 2022-03-14 19:53:05 +00:00
Jakob Bornecrantz 851224123e xrt: Add compositor semaphore interface 2022-03-14 19:52:48 +00:00
Jakob Bornecrantz 37354b953c aux/vk: Add more timeline semaphore functions 2022-03-14 18:58:35 +00:00
Jakob Bornecrantz 16bae922e2 c/main: Enable timeline semaphores where available 2022-03-14 18:58:35 +00:00
Christoph Haag dbb21715b0 st/oxr: Enable timeline semaphores where available
Co-authored-by: Jakob Bornecrantz <jakob@collabora.com>
2022-03-14 18:58:35 +00:00
Christoph Haag 02c456c192 st/oxr: Port XR_KHR_vulkan_enable2 init to u_string_list 2022-03-14 18:58:35 +00:00
Jakob Bornecrantz f4f2196e34 xrt: Add a way to say that timeline semaphores have been enabled 2022-03-14 18:58:35 +00:00
Jakob Bornecrantz d0f6ea10bc u/worker: Fix some late feedback 2022-03-14 18:57:35 +00:00
Jakob Bornecrantz bb363e53f5 doc: Document !1171 2022-03-14 17:39:23 +00:00
Jakob Bornecrantz 84069cc4f0 u/logging: Add logging sink to intercept log messages 2022-03-14 17:21:20 +00:00
Antonio Ospite 6ca4522de0 d/ns: really silence -Wunused-result warning
A previous change didn't really ignore the return value of fread() and
a warning was still emitted:

-----------------------------------------------------------------------
[103/1571] Building C object src/xrt/drivers/CMakeFiles/drv_ns.dir/north_star/ns_hmd.c.o
../src/xrt/drivers/north_star/ns_hmd.c: In function ‘ns_config_load’:
../src/xrt/drivers/north_star/ns_hmd.c:512:8: warning: ignoring return value of ‘fread’, declared with attribute warn_unused_result [-Wunused-result]
  512 |  (void)fread(json, 1, file_size, config_file);
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-----------------------------------------------------------------------

Check the return value of fread to fix the warning for good, and declare
the return value of ftell as long as stated in the man page.
2022-03-14 14:06:02 +00:00
Antonio Ospite 37852ffa65 xrt: fix -Wreturn-type warnings
Add some missing returns pointed out by -Wreturn-type:

-----------------------------------------------------------------------
[75/1571] Building C object src/xrt/auxiliary/CMakeFiles/aux_util.dir/util/u_config_json.c.o
.../src/xrt/auxiliary/util/u_config_json.c: In function ‘u_gui_state_scene_to_string’:
.../src/xrt/auxiliary/util/u_config_json.c:524:1: warning: control reaches end of non-void function [-Wreturn-type]
  524 | }
      | ^
-----------------------------------------------------------------------
2022-03-14 14:06:02 +00:00
utzcoz 112f02e0a9 doc: Add eigen3 package name hint for Debian/Ubuntu
Signed-off-by: utzcoz <utzcoz@outlook.com>
2022-03-12 12:11:14 +08:00
Ryan Pavlik ef89183f02 tests: Add u_worker tests 2022-03-11 15:29:16 +00:00
Jakob Bornecrantz 771aeda784 u/worker: Add task worker helper 2022-03-11 15:29:16 +00:00
Jakob Bornecrantz 76d8944765 os/threading: Add os_cond wrapper 2022-03-11 15:29:16 +00:00
Christoph Haag 7894039962 st/oxr: return defined result early on fail in xrLocateViews 2022-03-11 00:38:35 +01:00
Christoph Haag 4501088312 st/oxr: Don't return invalid pose after local space set up 2022-03-11 00:23:12 +01:00
Jakob Bornecrantz a0c8cc14f5 external: Update to Catch2 version 2.13.8 2022-03-09 22:34:40 +00:00
Jakob Bornecrantz e1b0f55a87 d/ns: Always check to close file on error path 2022-03-09 22:34:37 +00:00
Antonio Ospite a4167ee500 d/ns: silence -Wunused-result warning, close config_file in error paths
On some systems fread() is declared with  attribute warn_unused_result
and this results in a build warning:

-----------------------------------------------------------------------
Building C object src/xrt/drivers/CMakeFiles/drv_ns.dir/north_star/ns_hmd.c.o
.../src/xrt/drivers/north_star/ns_hmd.c: In function ‘ns_config_load’:
.../src/xrt/drivers/north_star/ns_hmd.c:512:2: warning: ignoring return value of ‘fread’, declared with attribute warn_unused_result [-Wunused-result]
  512 |  fread(json, 1, file_size, config_file);
      |  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-----------------------------------------------------------------------

Explicitly ignore the return value of that fread() to silence the
warning.

And while at it also close config_file in some error paths between
fopen() and fclose() which where leaking the file pointer when jumping
to the parse_error label.
2022-03-09 16:10:43 +01:00
Antonio Ospite beda8f35b2 xrt: fix -Wmissing-field-initializers warning in comp_window_wayland.c
Newer wayland protocols have a new filed in xdg_toplevel_listener which
is not initialized:

-----------------------------------------------------------------------
[215/315] Building C object src/xrt/compositor/CMakeFiles/comp_main.dir/main/comp_window_wayland.c.o
.../src/xrt/compositor/main/comp_window_wayland.c:182:1: warning: missing field 'configure_bounds' initializer [-Wmissing-field-initializers]
};
^
1 warning generated.
-----------------------------------------------------------------------

Detect the version when this is needed and initialize the field to
silence the warning.
2022-03-09 14:53:06 +01:00
Antonio Ospite e8c9d8f575 xrt: fix -Wunused-variable warnings
Some variables are only used in asserts, so they may be unused
depending on the build type:

-----------------------------------------------------------------------
[68/315] Building C object src/xrt/auxiliary/CMakeFiles/aux_util.dir/util/u_sink_combiner.c.o
.../src/xrt/auxiliary/util/u_sink_combiner.c:188:11: warning: unused variable 'diff_ns' [-Wunused-variable]
                int64_t diff_ns = frames[0]->timestamp - frames[1]->timestamp;
                        ^
1 warning generated.
[205/315] Building C object src/xrt/compositor/CMakeFiles/comp_main.dir/main/comp_renderer.c.o
.../src/xrt/compositor/main/comp_renderer.c:872:17: warning: unused variable 'layer_count' [-Wunused-variable]
        const uint32_t layer_count = c->base.slot.layer_count;
                       ^
1 warning generated.
-----------------------------------------------------------------------

Mark them as XRT_MAYBE_UNUSED to fix the build warnings.
2022-03-09 14:53:06 +01:00
Antonio Ospite 14a1ced0e4 xrt: fix -Wreturn-type warnings
Add some missing returns pointed out by -Wreturn-type:

-----------------------------------------------------------------------
[32/315] Building C object src/xrt/auxiliary/CMakeFiles/aux_gstreamer.dir/gstreamer/gst_sink.c.o
.../src/xrt/auxiliary/gstreamer/gst_sink.c:53:1: warning: non-void function does not return a value in all control paths [-Wreturn-type]
}
^
1 warning generated.
[84/315] Building C object src/xrt/auxiliary/CMakeFiles/aux_vk.dir/vk/vk_compositor_flags.c.o
.../src/xrt/auxiliary/vk/vk_compositor_flags.c:117:1: warning: non-void function does not return a value in all control paths [-Wreturn-type]
}
^
.../src/xrt/auxiliary/vk/vk_compositor_flags.c:146:1: warning: non-void function does not return a value in all control paths [-Wreturn-type]
}
^
2 warnings generated.
-----------------------------------------------------------------------

For the function returning VkImageAspectFlags return a literal 0 because
the enum values VK_IMAGE_ASPECT_NONE or VK_IMAGE_ASPECT_NONE_KHR may not
always be defined.
2022-03-09 14:52:29 +01:00
Jakob Bornecrantz 17e9e06de7 aux/vk: Detect external semaphore support 2022-03-08 21:04:56 +00:00
Jakob Bornecrantz c0bd8ce3ba aux/vk: Let vk_init_from_given enable timeline semaphores 2022-03-08 21:04:56 +00:00
Jakob Bornecrantz 3c8378631f aux/vk: Properly set log_level in given vk_bundles 2022-03-08 21:04:56 +00:00
Jakob Bornecrantz 3044794f93 aux/vk: Rename timeline_semaphores to features.timeline_semaphore 2022-03-08 21:04:56 +00:00
Jakob Bornecrantz 8bda87c855 xrt: Correct xrt_compositor_fence::wait docu 2022-03-08 21:04:56 +00:00
Moses Turner 30b779e515 t/hand: Add ht_sync 2022-03-08 20:44:25 +00:00
Moses Turner 012c86352e t/hand: Add async wrapper around sync helper
Co-authored-by: Jakob Bornecrantz <jakob@collabora.com>
2022-03-08 20:44:18 +00:00
Jakob Bornecrantz 60cd630271 tracking: Add new hand tracking interface header
Co-authored-by: Moses Turner <moses@collabora.com>
2022-03-08 20:38:58 +00:00
Moses Turner 7235b6a45a u/sink: Add some comments 2022-03-08 20:38:58 +00:00
Moses Turner 37f0c901d2 u/sink: Add sink to convert from stereo to two SLAM frames 2022-03-08 20:38:58 +00:00
Moses Turner a9db1a6f6e d/ht_crtl_emu: Free driver 2022-03-08 13:52:23 -06:00
Moses Turner 1b850a1f7d scripts: Init Git LFS when getting hand-tracking models 2022-03-08 13:52:23 -06:00
Jakob Bornecrantz 7b0cee5a85 u/trace_marker: Add new tracking category 2022-03-08 10:46:48 +00:00