Commit graph

1243 commits

Author SHA1 Message Date
Jakob Bornecrantz 11539e28b7 ipc/server: Fix swapchain being swapped left and right 2020-04-30 14:00:27 +01:00
Ryan Pavlik 457d411016 comp: Remaining 32-bit warning fixes 2020-04-29 17:47:32 -05:00
Ryan Pavlik 233c63a773 comp: Fix Wint-to-pointer-cast warnings on 32-bit.
Culprit is a Vulkan non-dispatchable handle:
Fix is simpler than for OpenXR because we aren't a Vulkan
implementation so they're all opaque to us.
2020-04-29 17:44:07 -05:00
Ryan Pavlik 53f9eb332d st/oxr: Fix more pointer conversion warnings. 2020-04-29 17:44:07 -05:00
Ryan Pavlik e89a3c1d8f st/oxr: Fix 32-bit warnings when checking for null handles 2020-04-29 17:44:07 -05:00
Ryan Pavlik d95219810e st/oxr: Add XRT_CAST_OXR_HANDLE_TO_PTR macro 2020-04-29 17:44:07 -05:00
Ryan Pavlik cecb8f31af st/oxr: Add and use XRT_CAST_PTR_TO_OXR_HANDLE macro to avoid warnings.
Other places we do these similar conversions will need this same modification.
2020-04-29 17:44:07 -05:00
Jakob Bornecrantz 7a70f86b2d targets: Add and change targets to support service process 2020-04-29 15:13:43 +01:00
Jakob Bornecrantz 220f37a75d xrt: Add build config file for optinal components 2020-04-29 14:58:24 +01:00
Jakob Bornecrantz 7c8a8a3f87 ipc: Add code to enable a service process
This enables out of process compositing.
2020-04-29 14:58:24 +01:00
Lubosz Sarnecki 5ba751a239 c/renderer: Expose idle image control. 2020-04-29 09:58:52 +01:00
Pete Black 8082e8dbca c/renderer: Add new reset rendering function 2020-04-29 09:58:52 +01:00
Jakob Bornecrantz 8328577b88 cmake: Tidy whitespace (NFC) 2020-04-29 09:12:19 +01:00
Ryan Pavlik ee90eb1d7e d/vive: Fix typos 2020-04-28 16:49:13 -05:00
Ryan Pavlik ba71b6f027 t/cli: Add missing include 2020-04-28 16:49:13 -05:00
Ryan Pavlik 777f905ee1 t/cli: Fix typos 2020-04-28 16:49:13 -05:00
Ryan Pavlik cb3096128a d/vive: Fix build on Android NDK by switching byte order utilities. 2020-04-28 21:40:57 +00:00
Ryan Pavlik 974c68dead xrt: Re-arrange build to avoid unnecessary includes.
Avoid unintentionally including cJSON from the source tree when using system,
etc. This adds granularity to the usage of "external" sources.
2020-04-28 21:36:46 +00:00
Ryan Pavlik 47710e0532 t/openxr: Fix build without OpenGL 2020-04-28 21:36:46 +00:00
Ryan Pavlik 4fc8d3dbea st/gui: Fix build without OpenCV 2020-04-28 21:36:46 +00:00
Jakob Bornecrantz b2c987945e st/prober: Use and expose usb serial and manufacturer 2020-04-28 18:51:07 +00:00
Jakob Bornecrantz 80dd892987 xrt: Add serial and manufacturer to xrt_prober video device probing interface 2020-04-28 18:51:07 +00:00
Jakob Bornecrantz cb90837d97 d/v4l2: Add support for XRT_FORMAT_UYVY422 2020-04-28 11:46:31 +00:00
Jakob Bornecrantz c7903e2d5e u/sink: Add support for XRT_FORMAT_UYVY422 2020-04-28 11:46:31 +00:00
Jakob Bornecrantz 1de7eb7cc9 t/calibration: Add support for XRT_FORMAT_UYVY422 2020-04-28 11:46:31 +00:00
Jakob Bornecrantz 7602e555b0 xrt: Add the format XRT_FORMAT_UYVY422 2020-04-28 11:46:31 +00:00
Jakob Bornecrantz 59b7794172 xrt: Rename XRT_FORMAT_YUV422 to XRT_FORMAT_YUYV422 2020-04-28 11:46:31 +00:00
Jakob Bornecrantz a8941859d7 d/v4l2: A bit more extra error printing 2020-04-28 11:46:31 +00:00
Christoph Haag d4e4a690db d/vive_controller: Add basic 3dof vive_controller_driver
v2: Add basic 3DOF Index Controller support

Only the "gen1" watchman usb protocol is supported (almost same as vive wand).
Note: Lighthouse v2 data is not properly ignored, the IMU data is only parsed correctly
when controller is not hit by lighthouse lasers.

Supported:
* trigger value
* trigger button
* trackpad x, y
* trackpad touch
* thumbstick x, y
* thumbstick click
* system click
* a click,
* b click

Not supported:
* trigger touch
* touchpad force
* thumbstick touch
* system touch
* a touch
* b touch
* grip squeeze
* finger tracking
2020-04-28 10:22:42 +00:00
Christoph Haag 74a328e909 u/json: Add json getter
u_json_get() is much, much shorter than cJSON_GetObjectItemCaseSensitive().
2020-04-28 10:22:42 +00:00
Christoph Haag e3b74c2e70 d/vive: Fix _json_get_string 2020-04-28 10:22:42 +00:00
Christoph Haag 2c818d5051 xrt: Add duration to xrt_output_value
The Vive Controller driver benefits from knowing the duration because
the hardware supports vibrating for a specific duration.
2020-04-28 10:22:42 +00:00
Christoph Haag 88ce6b5dcc st/oxr: Add Vive Wand and Valve Index Controller bindings
v2: add vive & index haptic output to khronos/simple_controller
2020-04-28 10:22:41 +00:00
Christoph Haag 04ebc42666 d/vive: Make common functions available through vive_protocol.h
Move common code to vive_protocol.c
2020-04-28 10:22:41 +00:00
Ryan Pavlik 427808d09a build: Use version script in Meson build too. 2020-04-27 17:33:43 -05:00
Ryan Pavlik 95b5c03f10 build: Relink if version script changes. 2020-04-27 17:33:38 -05:00
Ryan Pavlik 75d5e5b9f2 t/psmv: Fix FTBFS on PPC.
Apparently EIGEN_PI isn't a double by default.
2020-04-27 20:18:31 +00:00
Jakob Bornecrantz a10e7fe968 d/psmv: Move led and rumble update to thread 2020-04-25 16:24:28 +01:00
Ryan Pavlik b8b6e958f2 xrt: Fix FTBFS on ppc64, s390x 2020-04-24 20:34:53 +00:00
Ryan Pavlik 7fab448cf0 build: Support building with system cJSON.
Fixes #62.
2020-04-24 20:34:53 +00:00
Ryan Pavlik a11f5cc429 target/oxr: Mark the runtime target as a module, not a shared library. 2020-04-24 20:34:53 +00:00
Ryan Pavlik 69b8e8455c external: Fix spelling error in imgui demo. 2020-04-24 20:34:53 +00:00
Ryan Pavlik fc686f27dd d/psmv: Codespell fix 2020-04-24 15:31:51 -05:00
Ryan Pavlik c191f4bc30 st/oxr: Codespell fixes 2020-04-24 15:30:46 -05:00
Ryan Pavlik b7e28b0eb8 d/psmv: Codespell fix 2020-04-24 15:30:46 -05:00
Ryan Pavlik 128abac9e8 comp: Codespell fixes. 2020-04-24 15:30:46 -05:00
Lubosz Sarnecki ba3b220ad2 c/renderer: Use gray as idle image color. 2020-04-22 22:00:13 +01:00
Jakob Bornecrantz 01c479468c d/psvr: Use the simple 3dof imu filter 2020-04-22 22:00:13 +01:00
Lubosz Sarnecki d81b3797ba c/meson: Expose include directory in meson 2020-04-22 22:00:13 +01:00
Pete Black ccb1b911f6 c/client: Get the supported formats from the fd compositor 2020-04-22 22:00:13 +01:00
Jakob Bornecrantz 0ad9a7406c os/threading: Add #pragma once 2020-04-22 21:59:20 +01:00
Jakob Bornecrantz e37d8f4cf5 xrt: Remove timestate from xrt_device interface 2020-04-16 17:29:34 +01:00
Jakob Bornecrantz 48957b97c2 os/time: Fix warnings on C++ 2020-04-16 14:51:08 +01:00
Jakob Bornecrantz 76f83364e3 os/ble_dbus: Check if bluetooth is available
Closes #65
2020-04-16 13:48:34 +00:00
Jakob Bornecrantz 530cbf0d6c os/ble: Detect errors better 2020-04-16 13:48:34 +00:00
Jakob Bornecrantz ded6a8a4b9 os/ble_dbus: Fix return check 2020-04-16 13:48:34 +00:00
Christoph Haag 99af2b76d3 d/hdk: Remove unused, accidentally left in code 2020-04-16 14:44:54 +02:00
Christoph Haag 511dd78376 d/hdk: Poll imu in thread & drain queue on every poll
Fix #67
2020-04-16 00:24:59 +02:00
Jakob Bornecrantz c8b4a00482 comp: Delay swapchain destruction until a safe time, like end frame. 2020-04-15 19:57:46 +01:00
Jakob Bornecrantz 061dbefbd0 u/threading: Add a new higher level threading helpers 2020-04-15 17:33:35 +00:00
Lubosz Sarnecki 916d7708c2 c/renderer: Don't wait for device idle every frame.
Do wait on device idle when destroying the swap chain.
Don't wait on device idle multiple times in resize.

Validation on NVIDA and AMD is happy when only keeping
the two idles when resizing and destroying the swapchain.
2020-04-15 18:07:17 +02:00
Lubosz Sarnecki e477452ac6 c/renderer: Add fences for each command buffer.
Wait for fences on vkQueueSubmit.
2020-04-15 18:07:17 +02:00
Lubosz Sarnecki 8d3a0938fa aux/vk: Add vkResetFences. 2020-04-15 16:43:57 +02:00
Lubosz Sarnecki bda1cdaee1 c/renderer: Use only one buffer counter cache.
Use the same counter for frame and command buffers, as their number is
equal, which is retrieved from swapchain.image_count.
Use the struct member num_buffers in favor of passing it as parameter.
Reuse some command buffer functions.
2020-04-15 16:43:57 +02:00
Lubosz Sarnecki ddc7ceb214 c/renderer: Don't wait on device idle after acquiring swapchain image.
vkAcquireNextImageKHR is synchronized with the present_complete
semaphore.
2020-04-15 16:43:57 +02:00
Lubosz Sarnecki a34ad629f7 c/renderer: Don't wait idle queue after present.
This is not nesseccary as the vkQueuePresentKHR is synchronized by the
render_complete semaphore.
2020-04-15 16:38:54 +02:00
Lubosz Sarnecki 6cb99ea8bf c/renderer: Return false when vkEndCommandBuffer fails. 2020-04-15 14:00:35 +02:00
Jakob Bornecrantz ec076a0d5b xrt: Add helper functions for xrt_swapchain 2020-04-11 15:44:44 +01:00
Jakob Bornecrantz 945f2c82ed targets: Move xrt_instance implementation into targets 2020-04-11 12:31:58 +01:00
Jakob Bornecrantz b5354c4d83 st/gui: Remove old video test 2020-04-11 12:31:55 +01:00
Jakob Bornecrantz 57f407f02e st/gui: Tidy CMakeLists.txt 2020-04-11 12:19:28 +01:00
Jakob Bornecrantz 85bceaceca st/prober: Tidy CMakeLists.txt 2020-04-11 12:19:28 +01:00
Jakob Bornecrantz 69043bbf33 xrt: Add helper functions to xrt_device. 2020-04-11 00:55:14 +01:00
Jakob Bornecrantz c39cb39643 st/oxr: Use new xrt_instance object 2020-04-10 13:48:18 +01:00
Jakob Bornecrantz bbc07ed5f2 st/prober: Provide a default implementation of xrt_instance interface 2020-04-10 13:48:18 +01:00
Jakob Bornecrantz fa0789343e targets: Add stub implementations of xrt_gfx_provider_create_fd
This is needed by st/prober's default implementation of xrt_instance.
2020-04-10 13:48:18 +01:00
Jakob Bornecrantz 3b084b5c91 xrt: Add new xrt_instance object 2020-04-10 13:32:25 +01:00
Jakob Bornecrantz 452c1c0ba3 d/v4l2: Tweaks for the ELP stereo camera 2020-04-10 12:29:21 +00:00
Jakob Bornecrantz 231d39185e t/file: Remove hacky file handling functions 2020-04-10 12:29:21 +00:00
Jakob Bornecrantz 2063bc30b8 st/prober: Load tracking config from json and use new settings struct 2020-04-10 12:29:21 +00:00
Jakob Bornecrantz a11aa689a7 st/gui: Save camera and calibration data using new settings 2020-04-10 12:29:21 +00:00
Jakob Bornecrantz bc31233570 xrt: Add new "settings" interface for sharing camera settings across components 2020-04-10 12:29:21 +00:00
Jakob Bornecrantz de20d87f87 xrt: Make it possible for the prober to pass in JSON data to the drivers 2020-04-10 12:29:21 +00:00
Jakob Bornecrantz 7b049a9d65 t/file: Expose non-hack version of the calibration data save function 2020-04-10 12:29:21 +00:00
Jakob Bornecrantz f47c384b79 u/json: Add bool getter function 2020-04-10 12:29:21 +00:00
Jakob Bornecrantz b5dd07f2fa u/file: Add file helpers 2020-04-10 12:29:21 +00:00
Pete Black c02f89dc18 comp: Spell check 2020-04-09 17:34:27 +01:00
Lubosz Sarnecki bf49a421ba c/direct: Use common init swapchain function.
Simplify and add error messages.
2020-04-09 16:15:17 +00:00
Lubosz Sarnecki 77207ed585 c/direct: Shorten displays member names. 2020-04-09 16:15:17 +00:00
Lubosz Sarnecki 29b771818e c/direct: Move common direct mode code to comp_window_direct.
Create code file for common direct mode code.

Make common functions take generic parameters.

Use common code in randr and nvidia back ends.

Remove redunant includes.
2020-04-09 16:15:17 +00:00
Lubosz Sarnecki 94bc4cba28 c/direct: Split NVIDIA and RandR backends.
Rename functions and structs.

Define unused function overrides separatelty.

c/window: Define new backend init methods.
2020-04-09 16:15:17 +00:00
Lubosz Sarnecki 4ddcca7abd w/direct_mode: Use same num_displays variable for NVIDIA and RandR. 2020-04-09 16:15:17 +00:00
Jakob Bornecrantz 1ccfa236db xrt: Tidy whitespace 2020-04-09 15:08:11 +01:00
Pete Black 80d1d29cb5 comp: Tidy and spell check 2020-04-09 14:50:35 +01:00
Jakob Bornecrantz 6fe02588f9 comp: Get num_images from the fd compositor 2020-04-08 15:20:36 +01:00
Jakob Bornecrantz 9d009784b6 st/gui: Show name of device when no modes are found 2020-04-08 10:51:12 +01:00
Jakob Bornecrantz 817ec2f2bc u/hashset: Fix ISO C++ warning 2020-04-07 16:19:55 +01:00
Lubosz Sarnecki 6b05c216ce c/settings: Add a bunch of display strings to NVIDIA whitelist.
Whitelist Oculus DK1, DK2 and CV1.
Whitelist Vive Pro and Valve Index.
2020-04-07 13:45:11 +00:00
Lubosz Sarnecki 56a8e80844 c/direct_mode: Print meaningful error if no display matches NVIDIA whitelist. 2020-04-07 13:45:11 +00:00
Lubosz Sarnecki 7da70568be c/direct_mode: Use VkDisplayModeParametersKHR.
In favor of own struct to determine best available mode.
The loop now also starts as one, as we do not need compare the 0th mode
it itself and returns if there is only one mode.
2020-04-07 15:38:11 +02:00
Lubosz Sarnecki 7afb012544 c/direct_mode: Check if NVIDIA path found any displays.
This helps failing earlier with an NVIDIA Optimus setup, which currently
is not supported.
2020-04-07 15:00:16 +02:00
Lubosz Sarnecki 6158a23dd9 c/direct_mode: Port to plain C. 2020-04-07 15:00:16 +02:00
Lubosz Sarnecki 16d6500923 c/direct_mode: Don't cache enumerated modes in a std:map. 2020-04-07 15:00:16 +02:00
Lubosz Sarnecki 015d9457fe c/direct_mode: Extract append_randr_display function
Don't allocate string when it's not needed.
2020-04-07 15:00:16 +02:00
Lubosz Sarnecki b399960f67 c/direct_mode: Cast display int only for comparision with size().
It is clearer to leave `int display` from settings as signed integer and
cast only for the comparision with the unsigned vector size.
2020-04-07 15:00:16 +02:00
Lubosz Sarnecki a449ed174a c/direct_mode: Create append_nvidia_entry_on_match function. 2020-04-07 15:00:16 +02:00
Lubosz Sarnecki f8c99b0230 c/direct_mode: Use ARRAY_SIZE macro. 2020-04-07 15:00:16 +02:00
Lubosz Sarnecki c0ae309415 c/direct_mode: Remove unused nv_modes map. 2020-04-07 15:00:16 +02:00
Lubosz Sarnecki 865b668ee7 c/xcb: Port to plain C.
The code was already essentialy C, just needed to replace the pairs with
structs and the vector with an array, it was fixed length anyway.

The code feels more natural in C.
2020-04-07 15:00:16 +02:00
Jakob Bornecrantz 46f51e8139 os/ble: Fix memory leak if we fail to find a device 2020-04-03 17:21:55 +01:00
Jakob Bornecrantz 4d7634845d st/prober: Print serial, product and manufacturer from udev 2020-04-03 14:10:07 +01:00
Jakob Bornecrantz 96edbd9249 st/prober: Print serial, product and manufacturer from libuvc 2020-04-03 14:09:56 +01:00
Lubosz Sarnecki 1b7b8c163f comp: Further remove unused struct field initializers. 2020-04-01 12:50:10 +00:00
Lubosz Sarnecki b6d8d4b458 comp: Don't initialize unused fields in Vulkan structs.
In order to save redundancy with initializing empty fields with NULL / 0
values and improve readability of the Vulkan code.

This patch also uses struct initializers where possible.

This essentially reverts 1eae45212e.
2020-04-01 12:50:10 +00:00
Lubosz Sarnecki 65d6ade6f3 d/ns: Remove redundant semicolons.
As found by C++ pedantic warnings.
2020-03-31 18:26:56 +02:00
Lubosz Sarnecki 4d0c49096d comp/window_direct_mode: Use XCB/Xlib interop.
Since there currently is no Vulkan extension that takes XCB handles to
aqcuire the display Xlib interop needs to be used.

Before this patch Monado was opening connections for both APIs, which
introduced overhead.

Even though all XCB handles can be casted to Xlib ones, this cannot be
done with the main xcb_connection_t / Display. In it's design the
interop between both APIs can create a xcb_connection_t from a XCB
handle, but not the other way round. So in an interop case the Xlib
connection is the main one, since it's on a higher level.
More information on this can be found here:
https://xcb.freedesktop.org/MixingCalls/

Unfortunately the clean solution for this would be to specify a Vulkan
extension that takes XCB handles. This would make sense since Vulkan
is aware of XCB in other parts of the API as well. In Mesa the Xlib
structs will be ultimately casted to XCB.
2020-03-31 17:47:17 +02:00
Lubosz Sarnecki 20f281631b comp: Don't leak xcb replies.
According the XCB documentation the reply structs must be freed. I found
this when running a minimal example related to the direct mode code in
valgrind.
2020-03-31 17:47:01 +02:00
Jakob Bornecrantz a8a4d8c3dd d/arduino: Add new flexible arduino based input device 2020-03-27 10:22:19 +00:00
Ryan Pavlik bc53be8562 t/imu_fusion: Clean up and improve comments 2020-03-26 12:00:26 +00:00
Ryan Pavlik 4c54ccd0fb d/psmv: Switch to using pre-filter 2020-03-26 12:00:26 +00:00
Ryan Pavlik 98ad405d59 d/psmv: Use all 6 calibration measurements to compute accel bias. 2020-03-26 12:00:26 +00:00
Ryan Pavlik 86b3d9f587 t/calibration: Provide read-only access to size as cv::Size in calibration wrapper 2020-03-26 12:00:26 +00:00
Ryan Pavlik 4f5e2aea4e aux/tracking: Fix the API that led to the error I hit. 2020-03-26 12:00:26 +00:00
Ryan Pavlik c6a574191d aux/tracking: Add image undistort/normalize cache mechanism 2020-03-26 12:00:26 +00:00
Ryan Pavlik cf883817c2 t/psmv: Retrieve more data from camera calib. 2020-03-26 12:00:26 +00:00
Ryan Pavlik d198e93fcb external: Update flexkalman 2020-03-26 12:00:26 +00:00
Jakob Bornecrantz 9ff0ee2e6a st/gui: Fix compilation issue with OpenCV
Closes #63
2020-03-25 19:59:16 +00:00
Jakob Bornecrantz 622c848fa2 t/calib: Silence missing reference warning 2020-03-25 16:32:16 +00:00
Jakob Bornecrantz dd5246ceaf d/dd: Use new pre-filter and 3DOF fusion, also tidy driver. 2020-03-25 13:58:51 +00:00
Jakob Bornecrantz 2a68f3c9d3 d/dd: Give correct delta into math_quat_integrate_velocity 2020-03-25 13:58:51 +00:00
Jakob Bornecrantz 99eda56d39 d/vive: Use new 3DOF fusion 2020-03-25 13:58:51 +00:00
Jakob Bornecrantz 3e5da414f7 aux/math: Add 3DOF imu fusion 2020-03-25 13:58:51 +00:00
Jakob Bornecrantz f2ebe74748 aux/math: Add a simple imu pre-filter 2020-03-25 13:58:51 +00:00
Jakob Bornecrantz 23a66eb031 aux/math: Add math_matrix_3x3_rotate_vec3 function 2020-03-25 13:58:51 +00:00
Jakob Bornecrantz 18373730a8 aux/math: Expand the vec3 functions 2020-03-25 13:58:51 +00:00
Jakob Bornecrantz 21e77b85d7 aux/math: Add quat from angle vector function 2020-03-25 13:58:51 +00:00
Jakob Bornecrantz e3516061bb u/var: Add expand RO values 2020-03-25 13:58:51 +00:00
Ryan Pavlik a974562d43 t/openxr: Unify configured files for Meson and CMake. 2020-03-23 17:29:43 -05:00
Ryan Pavlik 377ae07e53 xrt: Add missing SPDX tags 2020-03-23 17:29:43 -05:00
Ryan Pavlik 33236fb20a imgui: Add license texts 2020-03-23 17:29:43 -05:00
Ryan Pavlik 09c189b6ba build: Install more targets 2020-03-23 17:29:43 -05:00
Jakob Bornecrantz f8847912a7 os/ble: Fix error on not finding any device 2020-03-13 11:07:32 +00:00
Jakob Bornecrantz c99546e88f xrt: Add some docu to refcount function 2020-03-11 22:00:54 +00:00
Jakob Bornecrantz 6ecc1e30f3 xrt: Make stereo_camera_calibration refcounted
This allows the data to be safely shared and passed around, even allowing us
to tag frames with the data and passed around that way instead.

Since it now can be passed around more safely make the prober call the save
function instead of the calibration code. This then forms a basis for further
work where we can hook this up into a more proper configuration file.
2020-03-11 22:00:54 +00:00
Pete Black b6613db5d4 d/dd: Add Daydream driver 2020-03-11 21:36:49 +00:00
Pete Black 6b4ec70d14 aux/os: Add D-Bus based BLE code 2020-03-11 21:36:49 +00:00
Pete Black a0be6e139a xrt: Add xrt_vec2_i32 2020-03-11 21:36:49 +00:00
Pete Black 8597ad5ee8 u/bitwise: Add bitwise manipulator functions 2020-03-11 21:36:49 +00:00
Jakob Bornecrantz 0b63cb2da3 aux/math: Add vec2 squared length function 2020-03-11 20:37:20 +00:00
Jakob Bornecrantz 119dc283af u/mesh: Fix file brief 2020-03-11 20:37:20 +00:00
Christoph Haag de7d9de5ae st/oxr: Fill XrViewConfigurationView with new two call helper
The previous two call helper macro copied the entire input struct to output struct.
In particular this did not keep the .type and .next fields intact.

Rather than trying to keep those intact, each struct type should have its own fill function,
only filling in the data we actually want to fill in.
2020-03-11 05:10:07 +01:00
Jakob Bornecrantz 622320904a xrt: Misc tidy of u_var_timing 2020-03-09 20:01:38 +00:00
Jakob Bornecrantz a54b92162e comp: Fix accidental code change from commit 9b662596
Spotted by @mpiatka.
2020-03-09 14:40:10 +00:00
Christoph Haag e8ccb07db7 st/gui: Add compositor frame timing graph to debug ui 2020-03-09 12:59:12 +01:00
Christoph Haag a3118f5ef2 st/gui: Add custom imgui element for timing graph
Features:
* draws 6 level lines with labels
* draws a line for a reference timing
* reference timing can be bottom of the graph, or center
* range around (up from) the reference timing can be specified
* optional automatic rescaling of the graph
2020-03-06 01:56:29 +01:00
Ryan Pavlik 8548d3f7e6 build: Another missed linking fix. 2020-03-05 17:52:49 +00:00
Jakob Bornecrantz a03d1fbf97 d/rs: Use realsense2::realsense2 in cmake
Not sure if this is the correct thing todo as the librealsense example
doesn't use the realsense2::realsense2 form.

https://github.com/IntelRealSense/librealsense/blob/master/examples/cmake/CMakeLists.txt
2020-03-05 17:27:08 +00:00
Jakob Bornecrantz 59f0d0ff0a u/time: Use smaller xrt_config_os.h instead of xrt_config.h 2020-03-05 11:25:50 +00:00
Ryan Pavlik 46c9fa7c2b build: aux_util depends on aux_math. 2020-03-04 17:25:27 -06:00
Ryan Pavlik fe40691052 build: Start using version script to reduce the number of exported symbols 2020-03-04 09:55:16 -06:00
Ryan Pavlik 71c29425d4 build: Fix linking issues preventing the OpenXR runtime from working. 2020-03-04 09:54:47 -06:00
Ryan Pavlik 92205ab5be build: Refactor CMake build to use static libraries instead of object bundles.
This allows transitive dependencies to work easier and improves compatibility.
It takes a little bit more storage at build time, and possibly a little extra time.
2020-03-04 11:15:35 +00:00
Ryan Pavlik 91ba5d04bc st/prober: Fix some unused-thing warnings when building with fewer deps. 2020-03-04 11:15:35 +00:00
Ryan Pavlik f3eac87504 xrt: Correct usage of XRT_MAYBE_UNUSED on functions.
It shouldn't be used on a function marked "static inline" - that's
sufficient to avoid the warning. So, it should almost never be in
a header.
2020-03-04 11:15:35 +00:00
Ryan Pavlik 778315bc52 xrt: Fix layer violations in interface headers.
A few were including aux headers.
2020-03-04 11:15:35 +00:00
Ryan Pavlik b1b08a610c st/prober: Add missing includes 2020-03-04 11:15:35 +00:00
Jakob Bornecrantz d2126882f6 d/rs: Add missing include 2020-03-04 11:15:35 +00:00
Ryan Pavlik 443528030d d/psmv: Add missing include 2020-03-04 11:15:35 +00:00
Ryan Pavlik 601a079387 d/hydra: Add missing include 2020-03-04 11:15:35 +00:00
Ryan Pavlik 0cb53a8c53 d/vive: Add missing include 2020-03-04 11:15:35 +00:00
Ryan Pavlik 5a633905de t/psvr: Add missing include 2020-03-04 11:15:35 +00:00
Ryan Pavlik 2c271048c0 d/dummy: Fix typo in comment 2020-03-04 11:15:35 +00:00
Jakob Bornecrantz 2ded61258c build: Fix no drivers getting included on cmake
I'm pretty sure I already did this, I guess I dropped the patch by
misstake. Well here it is anyway.
2020-03-03 13:36:21 +00:00
Ryan Pavlik b1b451eb96 comp: Fix 32-bit warnings 2020-03-03 10:50:41 +00:00
Ryan Pavlik d4c5b37bc0 st/oxr: Fix 32-bit warnings 2020-03-03 10:50:41 +00:00
Ryan Pavlik 2aa3b27695 aux/vk: Fix 32-bit warning 2020-03-03 10:50:41 +00:00
Ryan Pavlik 5af6182810 comp: Fix 32-bit porting issues. 2020-03-03 10:33:14 +00:00
Ryan Pavlik ffa5a76cea comp/client: More 32-bit porting fixes 2020-03-03 10:33:14 +00:00
Ryan Pavlik 163b39b7a1 st/oxr: Fix some 32-bit porting warnings. 2020-03-03 10:33:14 +00:00
Ryan Pavlik 4d7a8d819c util/hashset: Add missing include. 2020-03-03 10:33:14 +00:00
Ryan Pavlik 7d10788232 include/xrt: Fix Vulkan-related build issue on 32-bit. 2020-03-03 10:33:14 +00:00
Ryan Pavlik 98b1b11604 include/xrt: Add a bit-width detection define. 2020-03-03 10:33:14 +00:00
Ryan Pavlik d7121e8df4 st/oxr: Fix the declaration of our entry points.
We need the attributes and calling convention to match the header
2020-03-03 10:33:14 +00:00
Ryan Pavlik 81d9983398 build: Improve handling of common dependencies, and portability 2020-03-03 10:33:14 +00:00
Ryan Pavlik fdaede836c build: Make it possible to turn off the main compositor lib and runtime target. 2020-03-03 10:33:14 +00:00
Jakob Bornecrantz 0619190d2b build: Refactor how config defines are handled
With loads of changes from Ryan.
2020-03-03 10:33:14 +00:00
Jakob Bornecrantz a925af90e7 xrt: Do not pass in timestate into compositor 2020-03-02 20:18:49 +00:00
Ryan Pavlik 807438bb69 os/time: Remove XRT_MAYBE_UNUSED usages.
static inline is sufficient to avoid warnings about unused functions.
2020-03-02 14:01:18 -06:00
Ryan Pavlik 31ee6a1966 os/time: Documentation. 2020-03-02 13:59:06 -06:00
Ryan Pavlik 8f0082e810 drivers: Clean up documentation.
Making the Modules page in Doxygen more consistent.
2020-03-02 12:35:49 -06:00
Ryan Pavlik fca21e83b0 aux/util: Provide a conversion function from CLOCK_MONOTONIC nanoseconds to adjusted time. 2020-03-02 12:34:19 -06:00
Ryan Pavlik 227e53d030 os/time: Clean up comments and ifdefs. 2020-03-02 12:24:49 -06:00
Jakob Bornecrantz ca3c266dc1 comp: Split client and main in the build system as well 2020-03-02 12:01:04 +00:00
Jakob Bornecrantz 8c06787d93 comp: Refactor documentation 2020-03-02 12:00:22 +00:00
Jakob Bornecrantz b308facf90 comp: Move all glue code into client folder 2020-03-02 12:00:22 +00:00
Jakob Bornecrantz 3ca7fbf2f0 comp: Remove common directory 2020-03-02 12:00:22 +00:00
Jakob Bornecrantz aeef692e08 xrt: Refactor out main compositor creating into own interface 2020-03-02 12:00:22 +00:00
Jakob Bornecrantz 09aa8794b2 aux/vk: Refactor out helper code into own library 2020-03-02 11:58:40 +00:00
Jakob Bornecrantz a7dff8284a xrt: Tidy xrt_vulkan_includes.h 2020-02-29 21:09:18 +00:00
Jakob Bornecrantz d4928e1a1c comp: Improve comment on vk_bundle 2020-02-29 21:09:18 +00:00
Jakob Bornecrantz e80775fb63 comp: Reuse vk_create_view function in swapchain 2020-02-29 21:09:18 +00:00
Jakob Bornecrantz 63ca028b83 t/hsv: Improve latency when debugging by pushing debug frame after all other frames 2020-02-29 16:20:41 +00:00
Jakob Bornecrantz b05cf3667a d/v4l2: Use timeval conversion function 2020-02-27 13:55:58 +00:00
Jakob Bornecrantz d375843b65 os/time: Add time getting and conversion functions
For Linux it is based on CLOCK_MONOTONIC.
2020-02-27 13:55:57 +00:00
Jakob Bornecrantz 039e29e7ad u/time: Tidy 2020-02-27 13:55:48 +00:00
Jakob Bornecrantz a228c3efff xrt: Slightly more correct Display typedef
Closes #49
2020-02-24 16:58:15 +00:00
Christoph Haag 1cf742a3dc comp: Add XRT_COMPOSITOR_DESIRED_MODE env var to choose mode for direct mode.
The variable should be set to the index in the enumeration of a modes according to VK_KHR_display.

Monado can print a list of available modes with their indices with the env var XRT_COMPOSITOR_PRINT_MODES=1.
2020-02-19 13:51:00 +00:00
Christoph Haag c2250e5af0 comp: print available modes with XRT_COMPOSITOR_PRINT_MODES=1
To not clutter the user's output with debug info, add a variable to print only the available modes.
2020-02-19 13:51:00 +00:00
Christoph Haag 6b8103f31b comp: Update nominal frame interval to match chosen mode in direct mdoe
This value is used in xrWaitFrame() to throttle the application's rendering
down to the refresh rate of the HMD.
2020-02-19 13:51:00 +00:00
Christoph Haag 36d6b71e8a comp: Choose best mode for direct mode by default
Best mode means: first maximize the rendered pixels, then maximize the refresh rate.
2020-02-19 13:51:00 +00:00
Jakob Bornecrantz 7207c50992 math: Add filter fifo helper 2020-02-18 13:33:22 +00:00
Christoph Haag 7403d45133 d/ohmd: Add quirk to rotate WVR2 display left
OpenHMD can't easily tell us the WVR SKU because it has to read it
from the config after opening the device, while the product string
is set at device list time.

As a workaround, recognize the WVR2 by its resolution.
2020-02-18 00:33:59 +01:00
Jakob Bornecrantz a4ed39bf65 d/ohmd: Select correct pano_warp_scale 2020-02-15 16:03:13 +00:00
Jakob Bornecrantz f974301877 d/rs: Process frame does not take ownership of the frame 2020-02-12 14:16:39 +00:00
Jakob Bornecrantz 42df1aab20 d/ns: Tidy code 2020-02-12 12:22:21 +00:00
Jakob Bornecrantz eee034c18d d/ns: Remove unused file 2020-02-12 12:22:08 +00:00
Jakob Bornecrantz 68422f6e3e d/ns: Fix all warnings and tidy code 2020-02-12 12:22:08 +00:00
Nova d4e034dd44 d/ns: Greatly extend the North Star driver 2020-02-12 12:22:07 +00:00
Jakob Bornecrantz fd9cef6493 d/vive: Use proper external include in meson 2020-02-10 20:38:19 +00:00
Jakob Bornecrantz 937e6fafb7 d/ns: Use RealSense 6DOF for tracking if available 2020-02-10 20:07:31 +00:00
Jakob Bornecrantz b75ac54fe6 d/ns: Only create a North Star hmd if config path is set 2020-02-10 20:07:31 +00:00
Jakob Bornecrantz d6d934e35f d/rs: Meson build 2020-02-10 20:07:31 +00:00
Jakob Bornecrantz 53201debdc d/rs: Add a simple pure 6DOF device, for the T26[1|5] devices 2020-02-10 20:07:31 +00:00
Nova d48022d55d u/json: Add a lot more helper functions 2020-02-09 21:06:47 +00:00
Nova 4cfd4c4657 math: Added vec3 math functions 2020-02-09 21:06:47 +00:00
Ryan Pavlik f3803f7365 t/imu: Update docs to specify units for gyro. 2020-01-31 17:19:54 +01:00
Ryan Pavlik afd5328bd6 t/imu: Add optional debug prints to simple IMU fusion.
By request of @pblack.
2020-01-31 17:19:48 +01:00
Ryan Pavlik a11ba04b96 aux/tracking: handle loading into empty mat 2020-01-31 17:19:48 +01:00
Ryan Pavlik 85761db12c aux/math: Update comment 2020-01-31 17:19:48 +01:00
Ryan Pavlik 84dfbf241f d/vive: Fix typo. 2020-01-31 10:47:52 +01:00
Ryan Pavlik c590a3f69b st/oxr: Fix segfault in conformance 2020-01-31 10:47:52 +01:00
Ryan Pavlik eaf834249b t/calib: Verify that storage location doesn't move for wrappers. 2020-01-31 10:47:52 +01:00
Jakob Bornecrantz fca0513b4e d/v4l2: Print out the card name during debugging 2020-01-26 19:37:37 +00:00
Jakob Bornecrantz 0df88dedca st/gui: Add support for Leap Motion Controller 2020-01-26 19:37:37 +00:00
Jakob Bornecrantz ca06c16eeb st/gui: Better conversion sinks 2020-01-26 19:37:37 +00:00
Jakob Bornecrantz 8aee77401b t/calib: Tweak printing and move assert to after printing 2020-01-26 19:37:37 +00:00
Jakob Bornecrantz be75fe823a t/calib: Fix default asymmetrical circles rows values 2020-01-26 19:37:37 +00:00
Pete Black a80ef43339 t/calib: Also accept L8 frames 2020-01-26 19:37:37 +00:00
Jakob Bornecrantz c14d709a85 u/sink: Better error printing in converters 2020-01-26 19:37:37 +00:00
Jakob Bornecrantz 405f68c98a u/sink: Convert handle YUV888 to RGB888 as well 2020-01-26 19:37:37 +00:00
Jakob Bornecrantz 50b3794816 u/sink: Add quirk support for Leap Motion Conrtoller 2020-01-26 19:37:37 +00:00
Jakob Bornecrantz 16eb05e089 u/sink: Make quirk sink creation parameters into a struct. 2020-01-26 19:37:37 +00:00
Jakob Bornecrantz f16230a2d5 u/sink: Add a converter sink that accepts yuv, yuyv or l8 2020-01-26 19:37:36 +00:00
Pete Black f45f69c9f2 u/sink: Add a deinterleaver sink 2020-01-26 19:37:36 +00:00
Jakob Bornecrantz 576fcac5ae xrt: Add interleaved stereo format 2020-01-26 19:37:36 +00:00
Jakob Bornecrantz e74fab4d14 d/ns: Correct directory in documentation 2020-01-26 17:04:34 +00:00
Jakob Bornecrantz 1bcf13ba7e u/mesh: Refactor and document 2020-01-26 16:00:14 +00:00
Jakob Bornecrantz 2114fc877d comp: Add option to draw wireframe 2020-01-25 20:19:13 +00:00
Jakob Bornecrantz 62addc7a9f d/ns: Add stub mesh generation code 2020-01-25 17:32:32 +00:00
Nova 981fe55a27 d/ns: Add North Star stub driver 2020-01-25 17:06:51 +00:00