Commit graph

2647 commits

Author SHA1 Message Date
Jakob Bornecrantz eea8036e91 c/client: Ensure that EGL_ANDROID_native_fence_sync 2021-01-11 16:50:02 +00:00
Christoph Haag 7a030e36ae build/meson: Build and run tests
closes #97
2021-01-07 22:15:08 +01:00
Christoph Haag 726c752db2 comp: Add support for list of optional device extensions
If one of the supplied optional extensions is VK_GOOGLE_display_timing and it is
supported by the driver, vk_bundle::has_GOOGLE_display_timing will be set to true.
2021-01-07 19:12:41 +01:00
Christoph Haag 4d652fef5a st/oxr: Implement XR_KHR_vulkan_enable2 2021-01-06 13:40:59 +00:00
Christoph Haag 3e4f9d5b6f external: Update OpenXR includes to 1.0.13 2021-01-06 13:40:59 +00:00
Christoph Haag f8a4f35572 oxr: Add XR_KHR_vulkan_enable2 to ext generator script 2021-01-06 13:40:59 +00:00
Christoph Haag 3085e29c97 u/hand_tracking: Curl fingers based on joint, increase total curl angle
When making a fist, different joints curl at different angles, reflect
this more directly in the code.

Also increase total curl to make it easier to hold ingame objects.
2021-01-06 13:34:31 +00:00
Christoph Haag 679a1233ee d/ht: Set up tracking origin with no offset 2021-01-06 13:29:36 +00:00
Christoph Haag e2c1bc1d16 xrt: Rename hand_origin to hand_pose
hand_origin is confusing because it implies it is the origin of the coordinate system the hand is in.
It actually is the hand pose in the "global" coordinate system.
2021-01-06 13:29:36 +00:00
Christoph Haag c84dbad03e u/device: Add U_DEVICE_ALLOC_NO_FLAGS
Allows using U_DEVICE_ALLOCATE without flags without a cast.
2021-01-06 13:29:36 +00:00
Christoph Haag d85224e7c3 d/ht: Don't create hand tracking driver without successful init
Fixes a crash when no calibrated camera is found.
2021-01-06 13:29:36 +00:00
Christoph Haag 7831e38c02 u/device: Assign left/right hand trackers if no controllers are available
Previously the left/right role assignment considered only device types
* XRT_DEVICE_TYPE_LEFT_HAND_CONTROLLER
* XRT_DEVICE_TYPE_RIGHT_HAND_CONTROLLER
* XRT_DEVICE_TYPE_ANY_HAND_CONTROLLER

This adds XRT_DEVICE_TYPE_HAND_TRACKER for consideration, but only if none
of the above are present.
2021-01-06 13:29:36 +00:00
Christoph Haag 6d7dff360c d/psmv: Scale rumble value on zcm1
The motor on my psmv controller does not rumble at amplitudes < 0.25.
2021-01-06 13:23:28 +00:00
Christoph Haag 3848d2be3f st/oxr: Add env vars for global tracking origin offset
This commit is a band aid until a more proper room setup is implemented.
It allows moving the tracking offset for the device roles head, left and right by a fixed value.

A y tracking offset OXR_TRACKING_ORIGIN_OFFSET_Y=1.0 would tell monado that the current tracking
origin is 1 meter above the desired tracking origin, e.g. when the headset was calibrated to a
(0,0,0) position while sitting on table 1 meter above the floor.

This environment variable affects STAGE space, but not LOCAL space.
2021-01-06 13:03:47 +00:00
Jae Lee a71de192e0 illixr: Add initial integration. 2020-12-29 23:44:57 +00:00
Jakob Bornecrantz 15320d9ebe c/client: Insert fence and give sync handle on layer_commit (EGL for now only) 2020-12-28 15:22:46 +00:00
Jakob Bornecrantz 32c9cb1bf3 c/main: Make sure to close sync handles on layer_commit 2020-12-28 15:22:06 +00:00
Jakob Bornecrantz c191c9a466 ipc: Support sending sync handles on layer_commit 2020-12-28 15:22:06 +00:00
Jakob Bornecrantz 84d4b6aaae ipc/shared: Support sending graphics sync handles 2020-12-28 15:22:06 +00:00
Jakob Bornecrantz 1302b07d68 xrt: Add sync_handle argument to layer_commit 2020-12-28 15:22:06 +00:00
Jakob Bornecrantz 8e5f952d55 external: Update EGL bindings and more extensions 2020-12-28 15:22:06 +00:00
Jakob Bornecrantz e67ef85c0c t/ctl: Tidy printing 2020-12-28 14:21:03 +00:00
Lubosz Sarnecki 1038145ffd ipc: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 4acab28f3f c/client: Port printfs to static u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 34563276e8 targets/openxr/sdl2_hack: Port to static u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 12a3a24315 st/gui+steamvr_drv: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 521daac012 st/oxr: Port to u_logging.
Remove foo print.
Use correct ENV variable XRT_COMPOSITOR_LOG for Vulkan log.
2020-12-28 13:04:11 +00:00
Lubosz Sarnecki a8b01a89f3 st/prober: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 55d6d57392 aux/math: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki ba1d966f9f aux/vk: Port to u_logging.
Fix log calls where no valid state struct was provided.
2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 58ecf67515 aux/tracking: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki e350e42ca9 aux/os/ble_dbus: Use printf padding. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 79dde59f7e aux/os/ble_dbus: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 853458ed37 xrt: Port commented printfs to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 0302a47e6f d/realsense: Port to static u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 8ce0f73585 d/vive/conteroller: Porting to static u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 0708863e55 d/ohmd: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki e0b2c4ad2e d/ohmd: Make env variables consistent with driver name. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 2dbb6a6bb8 d/daydream: Port to u_logging.
Port static printfs to u_logging.
2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 1ba7d803a0 d/hydra: Port to u_logging.
Port printfs to static u_logging.
2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 00b2778504 d/arduino: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 6a2221115d d/ns: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki a9703f6b39 d/survive: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 2be5e32b67 d/v4l2: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki e6b2c1f2c7 d/vf: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 1f85d1c2ba d/hdk: Port to u_logging. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki abad99b956 service: Use new u_logging ENV variable for compositor. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki adcd0aff1a u/logging: Implement global log level.
Adds a `XRT_LOG` environemnt option.

Example:
```
XRT_LOG=debug
```
2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 8bdff9a61a u/logging: Implement optional color logging.
Check if stderr is a tty.
2020-12-28 13:04:11 +00:00
Lubosz Sarnecki 9ce9fa9238 u/logging: Align log level prefixes. 2020-12-28 13:04:11 +00:00
Lubosz Sarnecki b1c700a500 d/survive: Ignore -Wignored-qualifiers in survive header. 2020-12-28 13:04:11 +00:00
Boris-Chengbiao Zhou 98ef9a8ef7 comp: Fix Wayland backend 2020-12-28 04:13:22 +01:00
Christoph Haag 31c4c14042 steamvr: Make serial unique by appending xrt_hand
Monado gives both Playstation Move controllers the same xrt device name.

fixes #109
2020-12-25 22:56:54 +01:00
Christoph Haag d5183336b3 d/ohmd: Add display left rotation for Oculus Rift DK2 2020-12-23 11:51:51 +01:00
Lubosz Sarnecki d55c2b016a d/vf: Use static logging if no object is provided.
Found by clang11 warning.
2020-12-16 15:10:10 +01:00
Lubosz Sarnecki 9351673e55 st/steamvr_drv: Silence unfixable OpenVR cpp warnings. 2020-12-16 15:10:10 +01:00
Lubosz Sarnecki d0262c8613 c/comp: Fix switch fall through warning in gcc10. 2020-12-16 15:07:28 +01:00
Lubosz Sarnecki c03decd4d9 d/ht: Remove unused variable. Fixes warning on gcc 10. 2020-12-16 15:02:46 +01:00
Jakob Bornecrantz c30c4c011d c/main: Silence warnings and make sure that layer configs are picked up 2020-12-15 14:27:31 +00:00
Lubosz Sarnecki 200fb5aeed c/layers: Don't build equirect code if not enabled. 2020-12-14 18:59:28 +00:00
Lubosz Sarnecki 4995854d06 c/layers: Implement equirect1 rendering.
Add equirect1 boilerplate, shader files, ubo and pipeline.
2020-12-14 18:59:28 +00:00
Lubosz Sarnecki dc45a201db c+ipc+st: Complete equirect1 boilerplate. 2020-12-14 18:59:28 +00:00
Lubosz Sarnecki c8bdfae83e src: Consistently append 1 to equirect1 code.
Rename XRT_FEATURE_OPENXR_LAYER_EQUIRECT_LEGACY to XRT_FEATURE_OPENXR_LAYER_EQUIRECT1.
Use correct define in verify_equirect1_layer function.
Rename equirect to equirect1.
meson: enable equirect1 by default.
2020-12-14 18:59:28 +00:00
Lubosz Sarnecki f334b8b6c7 src: Consistently append 2 to equirect2 code.
Rename XRT_FEATURE_OPENXR_LAYER_EQUIRECT to XRT_FEATURE_OPENXR_LAYER_EQUIRECT2.
Rename equirect to equirect2.
Rename shader files.
2020-12-14 18:59:28 +00:00
Christoph Haag b2337469a4 st/prober: Make video file input work with no camera connected 2020-12-14 18:55:15 +00:00
Christoph Haag 30d7001df1 ipc: Make OXR_DEBUG_GUI=1 work with monado-service 2020-12-14 18:53:07 +00:00
Christoph Haag 49202eda87 d/psvr: Make get_tracked_pose thread safe 2020-12-14 02:00:09 +01:00
Christoph Haag ada506513f comp: Add XRT_COMPOSITOR_DEFAULT_FRAMERATE variable, default to 60
This variable only has an effect if
* The compositor is not run in direct mode (which uses the actual refresh interval of the chosen mode)
* The HMD driver does not default to a refresh ate by settting hmd->screens[0].nominal_frame_interval_ns
2020-12-10 16:36:22 +01:00
Christoph Haag 99e8416cac comp: Hook up xcb fullscreen and display settings to variables 2020-12-10 16:33:38 +01:00
Christoph Haag 199536c575 comp: Default xcb window to VK_PRESENT_MODE_IMMEDIATE_KHR
VK_PRESENT_MODE_FIFO_KHR leads to unsteady 60 fps.
2020-12-10 16:33:34 +01:00
Jakob Bornecrantz 39186a1e1e ipc/server: Rename ipc_server_client.c to ipc_server_handler.c 2020-12-09 21:03:50 +00:00
Jakob Bornecrantz 4b74d6b7eb ipc/server: Remove (f)printf usage from code 2020-12-09 21:03:50 +00:00
Jakob Bornecrantz 1154e58d06 ipc/server: Refactor out per_client_thread 2020-12-09 21:03:50 +00:00
Jakob Bornecrantz 743c289be5 xrt: Code style 2020-12-09 21:03:50 +00:00
Jakob Bornecrantz a5bf14502c t/hand: Remove per frame printing 2020-12-09 21:03:50 +00:00
Christoph Haag 7b4ac89a8f t/hand: warn when rectification matrix doesn't match image matrix 2020-12-07 12:30:26 +00:00
Christoph Haag 693cd77ca3 t/hand: Add comment that rectification is expensive 2020-12-07 12:30:26 +00:00
Christoph Haag f0d21c1dcc d/vf: Add video file playback driver 2020-12-07 12:30:26 +00:00
Christoph Haag e480352cee t/hand: Add hand tracking module 2020-12-07 12:30:26 +00:00
Christoph Haag 717d3a27ef d/ht: Add hand tracking driver code skeleton 2020-12-07 12:30:26 +00:00
Christoph Haag f7a8e8810b xrt: Split hand tracking input name into left/right
oxr_hand_tracker now stores which xdev and input name it tracks.
2020-12-07 11:43:51 +00:00
Ryan Pavlik 61c36f5a52 t/oxr: Export the right symbol on Windows. 2020-12-06 23:07:05 +00:00
Ryan Pavlik ee755961fc comp: Guard more of the caps-detector with an ifdef. 2020-12-06 23:07:05 +00:00
Ryan Pavlik 8b4e3aafa5 comp: Remove unused macro 2020-12-06 23:07:05 +00:00
Ryan Pavlik 535f20b503 inc/xrt: Reference the Vulkan extension table from related data. 2020-12-06 23:07:05 +00:00
Ryan Pavlik 5ea9fe04a3 comp: Add comments near Vulkan extension lists about updating docs. 2020-12-06 23:07:05 +00:00
Ryan Pavlik 90e307bf8a util: Port logging to OutputDebugString on Windows 2020-12-06 23:07:05 +00:00
Ryan Pavlik 0cb64ce5bd comp/main: Windows work - got a window to appear! 2020-12-06 23:07:05 +00:00
Ryan Pavlik 2743790180 comp/main: Remove *nix-only include 2020-12-06 23:07:05 +00:00
Lubosz Sarnecki 049bc385b1 xrt: Remove unused XRT_DEVICE_ANDROID. 2020-12-01 18:05:32 +01:00
Lubosz Sarnecki cf2fe0e2c3 d/android: Use XRT_DEVICE_GENERIC_HMD device name. 2020-12-01 18:05:32 +01:00
Lubosz Sarnecki a3e5daaa18 android/service_taget: Store native window pointer as global. 2020-12-01 18:05:32 +01:00
Lubosz Sarnecki 5a2ff41c7a android/service_target: Init ipc server in Android service. 2020-12-01 18:05:32 +01:00
Lubosz Sarnecki 1430b1b22c ipc/server: Add Android main entry point which receives fd. 2020-12-01 18:05:32 +01:00
Lubosz Sarnecki baa68fac4f ipc/server_process: Don't init listen socket and epoll on Android.
As the equivalent is already done in Java.
2020-12-01 18:05:32 +01:00
Lubosz Sarnecki 3202922ce7 ipc/server: Factor out start_server_thread function. 2020-12-01 18:05:32 +01:00
Lubosz Sarnecki db95b34e6c android/Client: Start IPC process in thread. 2020-12-01 18:05:32 +01:00
Lubosz Sarnecki 373a3096a9 c/window_android: Use cached surface from IPC.
Create window if activity is cached for in process.
2020-12-01 18:05:32 +01:00
Lubosz Sarnecki 92dab7b75b android/Client: Create Android surface for OoP. 2020-12-01 18:05:32 +01:00
Lubosz Sarnecki 37e87d1942 android/MonadoView: Make native pointer optional. 2020-12-01 18:05:32 +01:00
Lubosz Sarnecki 0a6bfe6d96 aux/android_globals: Provide API to store a native window globally. 2020-12-01 18:05:32 +01:00
Lubosz Sarnecki 020df327fa MonadoView: Don't be a Hilt view. Resolve exception.
Resolves:

java.lang.IllegalStateException: class org.freedesktop.monado.auxiliary.MonadoView, Hilt view must be attached to an @AndroidEntryPoint Fragment or Activity.
2020-12-01 18:05:32 +01:00
Ryan Pavlik 4101b3d92d android: IPC/service-related cleanups. 2020-12-01 18:05:32 +01:00
Ryan Pavlik 974e7bd1d5 ipc/android: Be a foreground service 2020-12-01 18:05:32 +01:00
Ryan Pavlik b92646c778 t/oxr_android: Bind ServiceNotificationImpl 2020-12-01 18:05:32 +01:00
Ryan Pavlik fe6507d64e t/android_common: Implement IServiceNotification 2020-12-01 18:05:32 +01:00
Ryan Pavlik 94d747cac9 aux/android: Create an interface for handling foreground service notification 2020-12-01 18:05:32 +01:00
Ryan Pavlik a2a61cb5cf ipc/android: Improve Client 2020-12-01 18:05:32 +01:00
Ryan Pavlik 70542fbb3b t/oxr_android: Split android UI that is not target-specific to a separate common target. 2020-12-01 18:05:32 +01:00
Ryan Pavlik 2fe699d7c1 xrt/android: Actually start using dependency injection in Java/Kotlin code. 2020-12-01 18:05:32 +01:00
Ryan Pavlik 3c3d628f0c t/oxr_android: Add resources and build code to grab the CDDL license for display.
Used by a dependency of Hilt.
2020-12-01 18:05:32 +01:00
Ryan Pavlik 885dd1d4d5 gradle: Handle kotlin in multiple parts of the build 2020-12-01 18:05:32 +01:00
Ryan Pavlik fa840e1cd8 ipc/android: Initial port of parts to Kotlin. 2020-12-01 18:05:32 +01:00
Ryan Pavlik b2f751ae99 aux/android: More null checks 2020-12-01 18:05:31 +01:00
Ryan Pavlik f6aff9196a t/oxr_android: Mention out-of-proc in app name resource 2020-12-01 18:05:31 +01:00
Ryan Pavlik 9a92b8f76c st/oxr_android: Provide a shutdown runtime button in activity. 2020-12-01 18:05:31 +01:00
Ryan Pavlik e4a346ad0b ipc/android: Clean ups and debug messages 2020-12-01 18:05:31 +01:00
Ryan Pavlik d9053e0dc5 ipc/android: Single point of truth for action name. 2020-12-01 18:05:31 +01:00
Ryan Pavlik aa222ebba1 ipc/android: Clean up, adjust action name, adjust manifest. 2020-12-01 18:05:31 +01:00
Ryan Pavlik d9453c708e ipc/android: Bump minSdkVersion 2020-12-01 18:05:31 +01:00
Ryan Pavlik d53e2dd7e2 st/oxr_android: Add icon to VR Listener service 2020-12-01 18:05:31 +01:00
Ryan Pavlik 7b5aad0be2 st/oxr_android: Declare sensor usage in manifest 2020-12-01 18:05:31 +01:00
Ryan Pavlik 635542f905 gradle: Break release build on a // STOPSHIP comment 2020-12-01 18:05:31 +01:00
Ryan Pavlik 23e01fc656 gradle: Factor out the dependency versions to a build-wide variable 2020-12-01 18:05:31 +01:00
Lubosz Sarnecki 4d45bfeb1b cmake: Fix Android linking error 2020-12-01 18:05:31 +01:00
Lubosz Sarnecki 144a5751f6 android/ipc/Client.java: call connectSync.notify(). 2020-12-01 18:05:31 +01:00
Ryan Pavlik da68bf502b ipc/client: Start using Android-specific code if needed. 2020-12-01 18:05:31 +01:00
Ryan Pavlik 9c7cfa0229 ipc/android: Add Android-specific native code library. 2020-12-01 18:05:31 +01:00
Ryan Pavlik 3011e3c9f6 ipc/android: Add a blocking connect Java method, and small clean-ups. 2020-12-01 18:05:31 +01:00
Ryan Pavlik 04318b4104 meson: Generate a mock Android config header. 2020-12-01 18:05:31 +01:00
Lubosz Sarnecki d493044e55 d/android: Use display metrics instead of hardcoded Pixel 3 values. 2020-12-01 17:36:15 +01:00
Lubosz Sarnecki c0ab34a355 aux/android: Implement display metrics acquisition. 2020-12-01 17:36:15 +01:00
Lubosz Sarnecki ae76b5037d c/renderer: Fix right eye viewport when not pre-rotating.
Scale X / Y were swapped incorrectly.
2020-12-01 15:46:21 +01:00
Jakob Bornecrantz 6fc0e1cda5 u/sink_converter: Silence warning 2020-11-30 17:52:58 +00:00
Jakob Bornecrantz 242faf9b60 u/sink_converter: Refactor allocation function a bit more 2020-11-30 17:52:58 +00:00
Christoph Haag 3b992a4508 u/sink_converter: Remove u_sink_converter::frame 2020-11-30 15:38:21 +00:00
Christoph Haag 5a4df61885 u/sink_converter: Clarify dst frame of format conversions 2020-11-30 15:38:19 +00:00
Christoph Haag 49587412bd u/sink_converter: clarify ensure_data() 2020-11-30 15:38:15 +00:00
Christoph Haag 9873588d08 sdl2hack: Don't call SDL_Quit()
It crashes client applications that use SDL2 on their own.
2020-11-30 15:38:13 +00:00
Christoph Haag 3d3361706c os/threading: Fix typo in comment 2020-11-30 15:38:07 +00:00
Christoph Haag 3168eb750d d/remote: Only define __USE_MISC if not defined 2020-11-30 15:38:06 +00:00
Lubosz Sarnecki c4683bb059 c/renderer: Pre-rotate display for transformed surfaces.
This resolves VK_SUBOPTIMAL_KHR warnings when preseting the swap chain
on systems likes Android.

https://android-developers.googleblog.com/2020/02/handling-device-orientation-efficiently.html
2020-11-27 16:50:55 +01:00
Lubosz Sarnecki bd68c0e5f5 aux/math: Implement math_matrix_2x2_multiply. 2020-11-27 16:50:55 +01:00
Christoph Haag f6839ee4bf st/oxr: Add view space case to hand tracking data 2020-11-23 20:42:54 +00:00
Christoph Haag f7cbe37c2d u/hand_tracking: Tweak hand model parameters
* shortened way too long bones
* tweaked offset positions
2020-11-23 20:42:54 +00:00
Christoph Haag 006971ae7a u/hand_tracking: Calculate joint velocities
And return them in the state tracker
2020-11-23 20:42:54 +00:00
Christoph Haag aa6e5f7fdf u_hand_tracking: Fix typo in u_hand_tracking_model 2020-11-23 20:42:54 +00:00
Christoph Haag 191fe7a59f st/oxr: Add verification of XrHandJointVelocitiesEXT 2020-11-23 20:42:54 +00:00
Christoph Haag f5ef3985ba xrt: Add support for locating hand joints in action spaces 2020-11-23 20:42:54 +00:00
Christoph Haag 95af586654 aux: Add m_space_graph_add_inverted_relation 2020-11-23 20:42:54 +00:00
Christoph Haag d6b072805a aux: Add m_space_relation_invert 2020-11-23 20:42:54 +00:00
Ryan Pavlik 4307ee8a08 st/oxr: Fix exporting of negotiate function. 2020-11-23 14:27:21 -06:00
Ryan Pavlik de36a64f27 st/gui: Don't export symbols from cimgui 2020-11-23 14:27:21 -06:00
Ryan Pavlik b0549b374a external: Don't export symbols from cjson 2020-11-23 14:27:21 -06:00
Ryan Pavlik 883fe27aed t/gui: Fix linking on Windows 2020-11-23 14:27:21 -06:00
Ryan Pavlik 147dcc24e0 comp/main: Fix finding M_PI 2020-11-23 14:27:21 -06:00
Ryan Pavlik 8b4c473233 comp/main: Change annotation for struct packing for MSVC compatibility. 2020-11-23 14:27:21 -06:00
Ryan Pavlik 6fbd12bde4 comp/main: near and far are keywords on Windows. 2020-11-23 14:27:21 -06:00
Ryan Pavlik 66811b436a xrt: Have the vk_helper vk_create_device take in a list of device extensions, and fix usages. 2020-11-23 14:27:21 -06:00
Ryan Pavlik 6c2b5d6614 comp/main: Clean up lists of extensions in main compositor 2020-11-23 14:27:21 -06:00
Ryan Pavlik af8459e407 inc/xrt: Comments 2020-11-23 14:18:20 -06:00
Ryan Pavlik 69a33c642d comp/client: Clean up Vulkan extension list, and add Windows extensions. 2020-11-23 14:18:20 -06:00
Christoph Haag d3ccbce76c build: meson: Add remote driver build 2020-11-20 16:14:02 +01:00
Jakob Bornecrantz 9bf58ec275 c/main: Make COMP_ERROR respect log level 2020-11-20 03:20:33 +00:00
Jakob Bornecrantz 6902f6d7a3 c/render: Change some COMP_ERROR to VK_ERROR 2020-11-20 03:20:33 +00:00
Jakob Bornecrantz 363703602e c/main: Tidy comp_target_swapchain 2020-11-20 03:20:33 +00:00
Jakob Bornecrantz ea723240e3 c/main: Tidy comp_android_window 2020-11-20 03:20:33 +00:00
Jakob Bornecrantz f4c1ebe90c c/main: Remove vk field from comp_target_swapchain 2020-11-20 03:20:33 +00:00
Jakob Bornecrantz d60ae941f1 c/main: Remove comp_window struct 2020-11-20 03:20:33 +00:00
Jakob Bornecrantz 9302bfa028 c/main: Move c field from comp_window to comp_target 2020-11-20 03:20:33 +00:00
Jakob Bornecrantz e8360c013d c/main: Refactor vk_swapchain into comp_target_swapchain 2020-11-20 03:20:33 +00:00
Jakob Bornecrantz 6260248d20 c/main: Introduce comp_target struct 2020-11-20 03:20:33 +00:00
Jakob Bornecrantz 78f7ad7301 c/main: Tidy vk_swapchain a bit 2020-11-19 01:13:23 +00:00
Jakob Bornecrantz ef6c8430d2 m/space: Make sure to not drop positions 2020-11-18 18:05:07 +00:00
Jakob Bornecrantz d1aa04e402 st/gui: Add remote hand tracking controls 2020-11-18 17:37:39 +00:00
Jakob Bornecrantz 5ce0a0b3ab d/remote: Add hand tracking support 2020-11-18 17:37:39 +00:00
Jakob Bornecrantz e0a7df0f1d st/oxr: Make sure to restore old EGL display/context/drawables when creating a EGL compositor 2020-11-15 22:47:42 +00:00
Christoph Haag a2b67ab3fe d/ohmd: Rotate rift s display right, not left 2020-11-12 16:04:00 +01:00
Christoph Haag 2efba6451e steamvr: support rotated displays and direct mode
Monado now calculates OpenHMD viewport dimensions and offsets correctly, we can pass those through.

The rotation of the rendered texture is performed with the distortion function.

v2: Use rotation matrix multiplication for distortion rotation
2020-11-12 16:04:00 +01:00
Christoph Haag 7ef8d1231d d/ohmd: Update display rotation code 2020-11-12 16:04:00 +01:00
Christoph Haag 9e788df463 xrt: Remove lens center from xrt_view
It's only used internally in drivers now.
2020-11-12 16:04:00 +01:00
Christoph Haag 0af755814c xrt: Improve comment documenting xrt_view::viewport 2020-11-12 16:03:27 +01:00
Christoph Haag c7ebf91821 xrt: Improve comment documenting xrt_view::display 2020-11-12 16:03:27 +01:00
Christoph Haag 1ad25d1050 xrt: Document that xrt_hmd_parts::screens dimensions are before rotation 2020-11-12 16:03:27 +01:00
Lubosz Sarnecki 8d628c43a9 ipc/server: Port printf calls to static u_logging.
Make messages more consistent.
2020-11-12 15:11:40 +01:00
Lubosz Sarnecki 23aa3652a3 ipc: Port to u_logging. 2020-11-12 15:11:40 +01:00
Ryan Pavlik 3328688f73 t/service-lib: Simplify. 2020-11-10 18:44:03 +00:00
Ryan Pavlik 86a19e6697 gradle: Remove unused dependencies. 2020-11-10 18:44:03 +00:00
Ryan Pavlik 451a9c5150 android: Update to AboutLibraries 8.5.0
This includes my submission allowing licenses to be
included explicitly in the gradle files.
2020-11-10 18:44:03 +00:00
Ryan Pavlik 5115124bb3 aux/android: Factor out a "native counterpart" class. 2020-11-10 18:44:03 +00:00
Christoph Haag 2082eddb65 steamvr: Fix running without controllers 2020-11-10 15:43:07 +01:00
Ryan Pavlik a792b08ed7 aux/vk: Minimal, untested implementations of these for Windows - fixes build 2020-11-10 03:09:07 +00:00
Ryan Pavlik dde20c14d3 t/oxr_android: Fix Doxygen warning. 2020-11-10 03:09:07 +00:00
Ryan Pavlik 9da004abb4 st/steamvr: Fix build on Windows. 2020-11-10 03:09:07 +00:00
Ryan Pavlik ec1375342f st/oxr: Fix outdated reference in docs. 2020-11-10 03:09:07 +00:00
Ryan Pavlik cc15bfa7ed a/util: FIx ambiguity of directories for docs. 2020-11-10 03:09:07 +00:00
Ryan Pavlik 4c4a204f22 cmake: Fix warning in SteamVR driver target 2020-11-10 03:09:07 +00:00
Ryan Pavlik 8f10d9c2b8 u_hand_tracking: Fix usage of M_PI 2020-11-10 03:09:07 +00:00
Ryan Pavlik a345b07308 d/psvr: Fix typo in config/debug macro 2020-11-10 03:09:07 +00:00
Ryan Pavlik d2955a3967 aux/util: Adjust conditional log macros to handle msvc correctly 2020-11-10 03:09:07 +00:00
Jakob Bornecrantz 135c93288b d/psvr: Rename some hid variables for better code 2020-11-09 23:42:15 +00:00
Jakob Bornecrantz aa7f922e35 os/time: Add a Linux specific way to get the realtime clock (for RealSense) 2020-11-09 23:42:13 +00:00
Jakob Bornecrantz 4bbe25148b os/time: Make timespec argument const 2020-11-09 23:42:11 +00:00
Ryan Pavlik 83b91ea4a9 d/ns: Some clang-tidy cleanups 2020-11-09 16:18:00 -06:00
Ryan Pavlik 97d711a9ef d/hdk: Appease clang-tidy a little more. 2020-11-09 16:18:00 -06:00
Ryan Pavlik 7cebdb4763 aux/os: More defines to calm clang-tidy. 2020-11-09 16:18:00 -06:00
Ryan Pavlik b855fd1ae2 a/util: Appease clang-tidy with a define for ns per second 2020-11-09 16:18:00 -06:00
Ryan Pavlik ab82c5b8e2 u_debug: Remove duplicate declaration 2020-11-09 16:18:00 -06:00
Ryan Pavlik 4c0d71aa30 d/ns: const correctness cleanup for math. 2020-11-09 16:17:57 -06:00
Ryan Pavlik d4011ed78a d/ns: Fix memory leak in math 2020-11-09 16:06:14 -06:00
Christoph Haag cb62514fd0 steamvr: Implement basic SteamVR driver
v3:
  targets: Add Monado-SteamVR driver target
  st/ovrd: Add OpenVR driver header
  build: Factor out sdl hack into lib_sdl2_hack and update steamvr build
  build: Revert lib_sdl2_refactor
  steamvr: Emulate Index Controller by default
  steamvr: Use oxr_handle_destroy instead of exposing oxr_instance_destroy
  steamvr: don't use oxr internals
  steamvr: communicate 3dof tracking to steamvr
  steamvr: use util functions for device assignment and tracking origin setup
  steamvr: Install plugin to <prefix>/share/steamvr-monado
  steamvr: Use thread for updating poses every 1ms

Makes a big difference for the Index @144Hz on the vive driver.
Still somewhat choppy on survive driver - prediction should solve it.

Main-author: Christoph Haag <christoph.haag@collabora.com>
Co-author: Jakob Bornecrantz <jakob@collabora.com>
2020-11-09 19:21:27 +00:00
Jakob Bornecrantz b6c3475352 external: Add OpenVR driver header 2020-11-09 00:32:33 +01:00
Christoph Haag 9d894ab5ff xrt: Move tracking origin setup code to u_device 2020-11-09 00:32:33 +01:00
Christoph Haag c60b7412e5 xrt: Move device assignment code to u_device 2020-11-09 00:32:33 +01:00
Benjamin Saunders 15a89005ca Fix trailing space in xrGetVulkanDeviceExtensionsKHR
Also tweak the instance extensions definition for consistency.
2020-11-07 12:50:25 -08:00
Christoph Haag 29820345c7 d/survive: Fix bindings declaration after rebase of MR 587 2020-11-06 16:36:09 +01:00
Christoph Haag 5478bad3d0 st/oxr: Add OXR_FRAME_TIMING_SPEW var to print basic frame timing information 2020-11-06 00:51:24 +01:00
Christoph Haag 2a00c9f09e comp: Add basic frame timing information to trace log 2020-11-06 00:50:24 +01:00
Christoph Haag 803e9531ec aux: Use time since time_state creation for time_state timestamps
Easy to read timestamps and somewhat meaningful.
2020-11-05 23:11:03 +00:00
Christoph Haag 2e2a62ce1a st/oxr: submit layers with os monotonic timestamp, not XrTime
The compositor does not know about XrTime, only os monotonic timestamps.
2020-11-05 23:11:03 +00:00
Ryan Pavlik 3c13dbce43 t/oxr_android: Work on aboutLibraries usage. 2020-11-05 17:04:58 -06:00
Ryan Pavlik 25967f906b t/oxr_android: Generate license resource at build time. 2020-11-05 17:04:53 -06:00
Ryan Pavlik e1e7b92372 ipc/android: Add additional service options 2020-11-05 17:02:21 -06:00
Ryan Pavlik cb09e68f0c gradle: Allow python location to be explicitly specified in local.properties 2020-11-05 16:09:27 -06:00
Ryan Pavlik ed519b1601 t/oxr_android: Rename activity and add version field 2020-11-05 16:09:26 -06:00
Jakob Bornecrantz 1c98297aa0 st/oxr: Use new xdev providing binding 2020-11-05 14:44:04 +00:00
Jakob Bornecrantz b5e847c814 ipc: Add support for device provided bindings 2020-11-05 14:44:04 +00:00
Christoph Haag ffa7cc84c8 d/vive: Add device bindings 2020-11-05 14:44:04 +00:00
Christoph Haag 4b261219a2 d/survive: Add device bindings 2020-11-05 14:41:55 +00:00
Jakob Bornecrantz 12df35232a d/psmv: Add device bindings 2020-11-05 14:41:55 +00:00
Jakob Bornecrantz 24a3886e85 d/daydream: Add device bindings 2020-11-05 14:41:55 +00:00
Jakob Bornecrantz 5997708634 d/arduino: Add device bindings 2020-11-05 14:41:55 +00:00
Jakob Bornecrantz 7c807a8605 xrt: Add device driver provided bindings 2020-11-05 14:41:55 +00:00
Christoph Haag d0b126c1ee oxr: Add one missing mutex to active_wait_frames 2020-11-04 13:33:27 +00:00
Jakob Bornecrantz 2a9a0100bc d/psvr: Tidy code 2020-11-04 13:26:47 +00:00
Christoph Haag 7eaa7abb89 oxr: Implement additional xrWaitFrame/xrBeginFrame call order checks
Relevant CTS tests: https://github.com/KhronosGroup/OpenXR-CTS/pull/7
2020-11-04 00:37:21 +01:00
Christoph Haag 965fa60bff xrt: Move synchronized state test into oxr session
The compositor now moves immediately to visible/focused when polling.
The state tracker will generate relevant openxr state changes once the session is synchronized.

Properly working alternative to e03ee48dce (reverted in e7643de8db)
2020-11-04 00:37:10 +01:00
Christoph Haag 4709744d0a ipc: log ipc calls and dispatch with IPC_PRINT_SPEW 2020-11-03 22:32:58 +01:00
Christoph Haag 233f3cb234 ipc: hook up IPC_PRINT_SPEW and IPC_PRINT_DEBUG variables
for both server and client
2020-11-03 22:32:58 +01:00
Jakob Bornecrantz e7643de8db c/main: Revert "Transition to visible/focused after xrEndFrame, not xrWaitFrame"
This reverts commit e03ee48dce.
2020-11-03 21:04:05 +00:00
Ryan Pavlik 14fcd6be6a external: SPDX/REUSE compliance 2020-11-02 17:04:51 +00:00
Ryan Pavlik 5f70826ba5 xrt: Add misc missing copyright/license notices 2020-11-02 17:04:51 +00:00
Ryan Pavlik 0684daae4f clang-format configs: Fix SPDX tags 2020-11-02 17:04:51 +00:00
Ryan Pavlik ae62cfbaf6 doc: Add spdx tags. 2020-11-02 17:04:51 +00:00
Christoph Haag e03ee48dce comp: Transition to visible/focused after xrEndFrame, not xrWaitFrame
The application synchronizes its frame loop by "by calling xrWaitFrame,
xrBeginFrame and xrEndFrame in a loop."

Applications can discard frames by not calling xrEndFrame. If initial
frames are discarded, we should not consider the frame loop synchronized.

Previously a sequence like
  xrBeginFrame, xrWaitFrame, xrBeginFrame, xrWaitFrame, xrPollEvent, xrBeginFrame
failed because xrPollEvent the compositor emitted transitions to visible
and focused but they were not emitted in the state tracker, because the
oxr session had not internally tranisitioned to the synchronized state.
2020-10-31 20:14:49 +01:00
Ryan Pavlik 240b8f3047 t/oxr_android: Include library attribution/notices in "about" activity. 2020-10-30 18:20:36 -05:00
Ryan Pavlik f70b1abd88 d/android: Use not-deprecated API when possible. 2020-10-30 18:20:36 -05:00
Lubosz Sarnecki ae1d4e9541 d/android: Enable cardboard distortion. 2020-10-30 18:20:36 -05:00
Lubosz Sarnecki f4113ef15b d/android: Add Android sensors driver. 2020-10-30 18:20:35 -05:00
Ryan Pavlik ad42bbff9e t/oxr_android: Move some distribution-related strings to build system 2020-10-30 18:20:35 -05:00
Ryan Pavlik 55eab2d79b t/oxr_android: Set package version from Git 2020-10-30 18:20:35 -05:00
Ryan Pavlik 36a9273db2 t/oxr_android: Match theme to temporary logo 2020-10-30 18:20:35 -05:00
Ryan Pavlik f46b801ad4 t/oxr_android: Improve VR Mode status messages 2020-10-30 18:20:35 -05:00
Ryan Pavlik 36fa605ab4 t/oxr_android: Add fragment to the main activity 2020-10-30 18:20:35 -05:00
Ryan Pavlik 03a129a4ea t/oxr_android: Add VrModeStatus fragment. 2020-10-30 18:20:35 -05:00
Ryan Pavlik ce3750bfe1 a/android: Store a native pointer in the MonadoView. 2020-10-30 18:20:35 -05:00
Ryan Pavlik 3bc84cca9e a/android: Migrate to using the MonadoView generated wrapper. 2020-10-30 18:20:35 -05:00
Ryan Pavlik b6a12f8522 a/android: Add some partially-generated wrappers for our own Java code. 2020-10-30 18:20:35 -05:00
Ryan Pavlik 0325409210 external/android-jni-wrap: Upgrade base header for new features 2020-10-30 18:20:34 -05:00
Ryan Pavlik fc78b5de86 a/android: Use android_custom_surface constructor/destructor 2020-10-30 18:20:34 -05:00
Ryan Pavlik 66d6281a7f a/android: Monitor whether MonadoView is still being used by native code. 2020-10-30 18:20:34 -05:00
Ryan Pavlik 6f989f5451 t/oxr_android: Clean up main activity. 2020-10-30 18:20:34 -05:00
Jakob Bornecrantz 75ff836e3b ipc: Add ipc_android doc group 2020-10-29 17:02:06 +00:00
Jakob Bornecrantz 585bb6fe7a ipc: Add ipc_shared doc group 2020-10-29 17:02:06 +00:00
Jakob Bornecrantz 3008e5482d ipc: Refactor folders 2020-10-29 17:02:06 +00:00
Jakob Bornecrantz 5ba3486628 t/[gui|oxr]: Directly reference SDL2 in CMake
This fixes the build when building with clang and CMake.
2020-10-29 16:33:15 +00:00
Jakob Bornecrantz 09ba7fc1e3 d/remote: Fix warning when building with clang 2020-10-29 16:17:20 +00:00
Ryan Pavlik 26cd22b232 a/android: Move class name to a constant. 2020-10-28 12:12:31 -05:00
Ryan Pavlik da3959e642 a/android: C++ headers use .hpp as the extension 2020-10-28 12:12:31 -05:00
Ryan Pavlik 8301c9d1b4 a/android: Fix some file comments. 2020-10-28 12:12:31 -05:00
Ryan Pavlik 941c6286e5 t/oxr_android: Add version annotation to the VR listener 2020-10-28 12:12:31 -05:00
Ryan Pavlik e724a72fc1 st/oxr_android: Adjust name string 2020-10-28 12:12:31 -05:00
Ryan Pavlik e4e3ee888a st/oxr_android: Clean up manifest 2020-10-28 12:12:31 -05:00
Ryan Pavlik 1acadb8a18 a/android: Make MonadoView fullscreen. 2020-10-28 12:12:31 -05:00
Ryan Pavlik 307b3f28fa t/oxr_android: Clean up manifest 2020-10-28 12:12:31 -05:00
Ryan Pavlik bcb6e85f9d t/oxr_android: Rename the VrListener class/service. 2020-10-28 12:12:31 -05:00
Lubosz Sarnecki a8c7ac2074 c/eglimage_swapchain: Actually return created swapchain. 2020-10-28 12:12:31 -05:00
Lubosz Sarnecki af4c6a8ba3 c/gl_client: Check if swapchain is not NULL. 2020-10-28 12:12:31 -05:00
Lubosz Sarnecki bd107095fd c/gl_client: Port to u_logging. 2020-10-28 12:12:31 -05:00
Lubosz Sarnecki e3df2f9940 st/oxr: Add GLES Android session boilerplate. 2020-10-28 12:12:31 -05:00
Lubosz Sarnecki d61faff421 aux/android/ahardwarebuffer_allocator: Use Vulkan enums in format switch. 2020-10-28 12:12:31 -05:00
Lubosz Sarnecki 633b7839c2 aux/vk+comp/sc: Initialize extra structs for hardware buffer extension.
Fix sRGB format for Android hardware buffers.
2020-10-28 12:12:31 -05:00
Lubosz Sarnecki 3cc8793d7d aux+comp: Add Android hardware buffer device extension. 2020-10-28 12:12:31 -05:00
Lubosz Sarnecki 2cc8252c05 aux/vk: Add vkGetAndroidHardwareBufferPropertiesANDROID. 2020-10-28 12:12:31 -05:00
Lubosz Sarnecki 2df2daa00c aux/android/ahardwarebuffer_allocator: Add function to allocate a single buffer. 2020-10-28 12:12:31 -05:00
Ryan Pavlik 436886852d a/android: Improve monadoview, including fixing deleted ref problem. 2020-10-28 12:12:31 -05:00
Ryan Pavlik a0bbca572d comp: Basic Android compositor window.
Also makes the service feature not depend on other options:
it can be used without those other parts.

comp/window_android: Remove unused EGL code for now, as it is crashing.

comp/window_android: Use MonadoView async method to create surface.

comp/window_android: Use custom surface as intended

Co-authored-by: Lubosz Sarnecki <lubosz.sarnecki@collabora.com>
2020-10-28 09:41:30 -05:00
Ryan Pavlik dfd771f768 aux/android: Enhance custom surface
Includes fixes to my mistakes by Lubosz.

Co-authored-by: Lubosz Sarnecki <lubosz.sarnecki@collabora.com>
2020-10-28 09:41:03 -05:00
Lubosz Sarnecki e78ad12634 aux/android/custom_surface: Make JNI happy.
Keep android_load_class methods in C++, since
casting the class handle to void results in:

```
JNI DETECTED ERROR IN APPLICATION: use of deleted global reference.
```

Co-authored-by: Ryan Pavlik <ryan.pavlik@collabora.com>
2020-10-28 09:33:47 -05:00
Lubosz Sarnecki 2a8db3d780 aux/android/load_class: Use pkgClassLoader.loadClass to load MonadoView class. 2020-10-28 09:33:46 -05:00
Lubosz Sarnecki dbe0338956 android/MonadoView: Register surface callback and fix imports.
Run UI things on UI thread.
2020-10-28 09:33:46 -05:00
Lubosz Sarnecki c64d17fa88 comp/main: Define Android extensions. 2020-10-28 09:33:46 -05:00
Lubosz Sarnecki 79fd76f68d comp/main: Don't check for VK_KHR_display on Android. 2020-10-28 09:33:46 -05:00
Lubosz Sarnecki 7d02a93ca5 android/manifest: Extract libs. 2020-10-28 09:33:46 -05:00
Ryan Pavlik 43d724b6bf aux/vk: Fix a place where we were missing an android ifdef 2020-10-28 09:33:46 -05:00
Ryan Pavlik d4b19f3d47 aux/android: Add custom surface code. 2020-10-28 09:33:46 -05:00
Ryan Pavlik 9b67c0a09f aux/android: Add code to load Java from a package 2020-10-28 09:33:46 -05:00
Ryan Pavlik 2cafdfa5cc t/oxr_android: Add Android-specific subdirectory 2020-10-28 09:33:46 -05:00
Ryan Pavlik d6564e3798 ipc_android: Add Android-specific Java/AIDL code 2020-10-28 09:33:46 -05:00
Ryan Pavlik d0187cee9a aux/android: Add Java code 2020-10-28 09:33:26 -05:00
Ryan Pavlik 0f43bbe924 inc/xrt: Add Android config header to store package name. 2020-10-28 09:32:49 -05:00
Ryan Pavlik 06f75e03b4 a/android: Fix typo in comment 2020-10-28 09:32:49 -05:00
Ryan Pavlik 0ea7cf8009 targets: Add service-lib stub for Android 2020-10-28 09:32:49 -05:00
Ryan Pavlik 59d2285c8e aux/util: Port logging for Android.
Now if u_logging is used, it goes to logcat.
2020-10-28 09:32:49 -05:00
Ryan Pavlik 82037070a9 external: Add android-jni-wrap. 2020-10-28 09:32:49 -05:00
Ryan Pavlik bf36c5c522 external: Import jnipp 2020-10-28 09:32:49 -05:00
Jakob Bornecrantz 463330d5d5 u/distortion: Set blend mode incase it is zero 2020-10-27 21:34:29 +00:00
Jakob Bornecrantz ecbde55752 m/space: Normalize orientation when returning result 2020-10-27 16:20:12 +00:00
Jakob Bornecrantz 09566cf5fd c/main: Fix projection layer flags not getting set 2020-10-27 16:05:13 +00:00
Jakob Bornecrantz bd6ea43de5 m/headers: Fix doxygen warnings 2020-10-26 22:55:22 +00:00
Jakob Bornecrantz 8730ff479a u/hand_tracking: Tidy header 2020-10-26 22:50:54 +00:00
Jakob Bornecrantz d72776b82c d/psvr: Switch to logging API 2020-10-26 22:41:49 +00:00
Jakob Bornecrantz 6fd1e7b36c d/dummy: Add logging to variable tracking 2020-10-26 22:41:27 +00:00
Jakob Bornecrantz 02a3b47f7c d/dummy: Switch to logging API 2020-10-26 22:17:15 +00:00
Jakob Bornecrantz 3611193feb d/dummy: Tidy file 2020-10-26 22:14:05 +00:00
Jakob Bornecrantz cf8ca3756e c/main: Fix leaks of samplers and tidy code 2020-10-26 22:07:12 +00:00
Jakob Bornecrantz 75153a7066 u/distortion: Add simple cardboard distortion code 2020-10-26 21:53:55 +00:00
Jakob Bornecrantz ed2040a571 u/mesh: Tidy header 2020-10-26 20:36:30 +00:00
Jakob Bornecrantz 7bcdf0de40 st/prober: Depend on remote driver as we reference it directly 2020-10-26 20:35:18 +00:00
Jakob Bornecrantz f868f61a17 st/oxr: Improve verification of XrGraphicsBindingEGLMNDX 2020-10-26 14:05:27 +00:00
Jakob Bornecrantz 7ba4bee439 st/oxr: Minor fixes for oxr_session_egl 2020-10-26 14:03:30 +00:00
Jakob Bornecrantz ebfd984c12 st/oxr: Fix missing semicolons 2020-10-26 14:03:30 +00:00
Jakob Bornecrantz f9443cf362 st/oxr: Timeout minimum duration pulses after 0.1 seconds 2020-10-26 14:03:30 +00:00
Lubosz Sarnecki 663dfe8990 meson: Add equirect2 to build. 2020-10-26 01:34:10 +00:00
Lubosz Sarnecki 1227c77556 st/oxr: Add equirect2 verify and submit functions. 2020-10-26 01:34:10 +00:00
Lubosz Sarnecki 3195ba8351 c/main: Implement XR_KHR_composition_layer_equirect2. 2020-10-26 01:34:10 +00:00
Lubosz Sarnecki 9738b4fe93 c/shaders: Add equirect shader. 2020-10-26 01:34:10 +00:00
Lubosz Sarnecki 5777d829c6 c/comp: Init repeat sampler for swapchain images. 2020-10-26 01:34:10 +00:00
Lubosz Sarnecki 7035490ed7 aux/math: Implement math_matrix_4x4_inverse_view_projection. 2020-10-26 01:34:10 +00:00
Christoph Haag 74f7d03830 xrt: Add printing list of built in drivers to monado_cli probe 2020-10-25 22:59:06 +01:00
Christoph Haag f910367014 d/oh: Add startup delay for Rift S and rotate left 2020-10-21 01:26:53 +02:00
Jakob Bornecrantz fd5cfbe9a7 st/oxr: Fix state changes errors 2020-10-20 19:28:57 +01:00
Jakob Bornecrantz 2528583c55 xrt: Add git tag/description 2020-10-20 17:43:11 +01:00
Jakob Bornecrantz 9440a9dd93 st/prober: Add remote loading 2020-10-15 21:07:40 +00:00
Jakob Bornecrantz 27abc58d51 st/prober: Add the concept of active config to config file 2020-10-15 21:07:40 +00:00
Jakob Bornecrantz a122b4b0b2 st/prober: Refactor out adding functions. 2020-10-15 21:07:40 +00:00
Jakob Bornecrantz 541bdd2fce st/gui: Add remote device control ui 2020-10-15 21:07:40 +00:00
Jakob Bornecrantz 3483a7286d d/remote: Add remote driver 2020-10-15 21:07:40 +00:00
Jakob Bornecrantz 0cf3c704b6 st/oxr: Add simple controller bindings 2020-10-15 21:07:40 +00:00
Jakob Bornecrantz f3394320b1 xrt: Add simple controller input profile 2020-10-15 21:07:40 +00:00
Jakob Bornecrantz a200bd5fec st/oxr: Add option to disable printing to stderr 2020-10-15 01:45:51 +00:00
Jakob Bornecrantz 71e05fc21d st/oxr: Improve pose sub-path handling
If the client only supplies the 'any' path no sub-path would be
selected in the 'any' cause.
2020-10-15 01:45:51 +00:00
Jakob Bornecrantz 54739aff8d c/render: Refactor out distortion rendering 2020-10-13 19:51:13 +01:00
Jakob Bornecrantz c5741af98a c/main: Tidy names 2020-10-13 19:17:50 +01:00
Jakob Bornecrantz 4ffc0b4144 c/main: Remove viewport_id in mesh shader 2020-10-13 19:17:50 +01:00
Jakob Bornecrantz 95bdcc0bd3 c/main: Round viewport to cover the same as scissors 2020-10-13 19:17:50 +01:00
Jakob Bornecrantz 32fd9398fe c/main: Refactor shader loading to own file 2020-10-13 19:17:50 +01:00
Jakob Bornecrantz 438a8e71f9 aux/vk: Add vkFreeDescriptorSets 2020-10-13 18:59:28 +01:00
Christoph Haag c0a5b3b76c d/survive: Implement haptic feedback 2020-10-13 19:39:28 +02:00
Christoph Haag 0dcde4a597 d/vive: Actually Use defined values for default haptic frequency and min haptic duration 2020-10-13 19:39:28 +02:00
Christoph Haag 270a4143c7 d/vive: Use defines for minimum haptic frequency and unspecified haptic frequency 2020-10-13 19:39:25 +02:00
Christoph Haag 1f021a6eda xrt: Add defines for minimum haptic frequency and unspecified haptic frequency 2020-10-13 19:27:53 +02:00
Christoph Haag d959bea54a d/vive: curl thumb when touching a button 2020-10-12 22:55:33 +02:00
Christoph Haag 05f65e0028 d/survive: curl thumb when touching a button 2020-10-12 22:55:33 +02:00
Christoph Haag f8088c1fa4 d/survive: Add fingertracking and refactor
Get controller config at startup & determine variant.
2020-10-12 22:55:33 +02:00
Christoph Haag 5164488225 d/vive_controller: Add finger tracking 2020-10-12 22:55:33 +02:00
Christoph Haag ca5cbaaa6f aux: Add hand_tracking util 2020-10-12 22:55:33 +02:00
Christoph Haag 6e5206f232 ipc: Add missing position_tracking_supported passthrough 2020-10-12 22:13:48 +02:00
Christoph Haag 256e2c68d8 xrt: Implement & hook up hand joint tracking infrastructure
Include <inttypes.h> to satisfy older compilers
2020-10-12 22:13:47 +02:00
Christoph Haag 2a07c1034e d/ns: Don't create rs tracker twice on v1 2020-10-12 16:06:25 +02:00
Ryan Pavlik 9d8af39b4f t/cli: Fix build on Windows. 2020-10-08 17:26:23 -05:00
Ryan Pavlik 835beedcca u_handles: Add Win32 handle utilities 2020-10-08 17:26:22 -05:00
Ryan Pavlik 5522c7317a st/oxr: Replace __typeof__ usage with portable syntax.
Needed for building on MSVC
2020-10-08 17:26:22 -05:00
Ryan Pavlik 3faa32753d inc/xrt: have the vulkan includes include windows.h neatly.
The Vulkan header itself already does it, we just want to do it first
with the right defines.
2020-10-08 17:26:22 -05:00
Ryan Pavlik 39ede92287 build: Link aux_util against threads explicitly 2020-10-08 17:26:22 -05:00
Ryan Pavlik 8b416da12b xrt: Add Win32 Vulkan platform define when needed 2020-10-08 17:26:22 -05:00
Ryan Pavlik 938e8cb393 inc/xrt: Windows uses Win32 HANDLEs for things. 2020-10-08 17:26:22 -05:00
Ryan Pavlik 60b4fc2ba1 inc/xrt: Add a header for minimally including Windows.h 2020-10-08 17:26:22 -05:00
Ryan Pavlik 3f83b1da92 u_json: Properly silence secure CRT warnings. 2020-10-08 17:26:22 -05:00
Ryan Pavlik 48eb00f1c8 u_bitwise: Switch from static const int to defines.
Sadly MSVC didn't believe those were constant,
and this is a C file so no constexpr.
2020-10-08 17:26:22 -05:00
Jakob Bornecrantz 1750bb672f c/main: Remove none shaders 2020-10-08 15:02:52 +01:00
Jakob Bornecrantz 39ec39dbee c/main: Add more logging levels 2020-10-08 14:57:59 +01:00
Jakob Bornecrantz 813487c2f5 ipc: Use new none distortion code 2020-10-07 23:45:46 +01:00
Jakob Bornecrantz 96046d1315 d/ohmd: Use new none distortion code 2020-10-07 23:45:45 +01:00
Jakob Bornecrantz 7baf90d3d8 d/hdk: Use new none distortion code 2020-10-07 23:45:43 +01:00
Jakob Bornecrantz cd2ea960b9 d/dummy: Use new none distortion code 2020-10-07 23:45:41 +01:00
Jakob Bornecrantz 51c8575323 u/mesh: Add back none distortion generation 2020-10-07 23:45:39 +01:00
Jakob Bornecrantz b5e5322f49 c/main: Use log levels 2020-10-06 20:37:01 +01:00
Lubosz Sarnecki bbeab1da3f c/main: Use u_logging.
Remove comp_compositor_print.
2020-10-06 20:04:52 +01:00
Christoph Haag dc29c3f97e build/meson: Build daydream and arduino driver when dbus is enabled 2020-10-05 16:05:02 +00:00
Christoph Haag 5bea856f20 build/meson: Add XRT_HAVE_DBUS when dbus is found 2020-10-05 16:05:02 +00:00
Jakob Bornecrantz 92caeae39c xrt: Define XRT_FEATURE_COMPOSITOR_MAIN and XRT_FEATURE_OPENXR 2020-10-05 16:46:06 +01:00
Jakob Bornecrantz 942ba178a0 st/oxr: Add extension support for XR_KHR_composition_layer_equirect2 2020-10-05 16:45:48 +01:00
Jakob Bornecrantz 708dc80bbc external: Update OpenXR headers to 1.0.12 2020-10-05 16:34:12 +01:00
Jakob Bornecrantz c5b696cfd7 t/cli: Add lighthouse command 2020-10-05 16:22:02 +01:00
Jakob Bornecrantz 0804dc20d1 os/ble: Use logging 2020-10-05 16:22:02 +01:00
Jakob Bornecrantz 40c764a290 os/ble: Large refactor of code 2020-10-05 14:19:52 +01:00
Jakob Bornecrantz 5af976a510 os/ble: Add os_ble_broadcast_write_value function 2020-10-05 14:19:52 +01:00
Jakob Bornecrantz 5b4d45ffcc os/ble: Correct documentation on os_ble_notify_open function 2020-10-05 14:19:52 +01:00
Jakob Bornecrantz 33879da21a xrt: Add XRT_HAVE_DBUS 2020-10-05 14:19:52 +01:00
Christoph Haag a0dd182dae build/ctl: Explicitly depend on generated ipc client header
Including a header in the build target is the documented solution for depending on
the generation of files via custom targets.

Fixes build on alpine linux.
2020-10-04 23:44:16 +02:00
Jakob Bornecrantz 02b33c668b st/oxr: Destroy client compositor when session is destroyed
Fixes #99
2020-10-04 13:04:57 +01:00
Jakob Bornecrantz 9dd8bfef28 st/oxr: Use xrt_comp_native_destroy helper 2020-10-04 13:04:55 +01:00
Jakob Bornecrantz 3729f2e8c9 ipc: Free client side compositor 2020-10-04 13:04:53 +01:00
Jakob Bornecrantz 309037a445 c/client: The client compositors doesn't own the native compositor 2020-10-04 13:04:52 +01:00
Jakob Bornecrantz 6ec6c2eac9 d/dummy: Make view rotate slightly with time 2020-10-01 23:49:12 +01:00
Jakob Bornecrantz 9f39410b64 d/dummy: Make the view move slightly with time 2020-10-01 15:50:51 +01:00
Jakob Bornecrantz 9a675cc7f3 xrt: Rename xrt_uv_triplet 2020-09-30 15:35:57 +01:00
Christoph Haag bb56e5f3c5 d/openhmd: Make struct oh_device private and refactor 2020-09-30 02:08:03 +02:00
Christoph Haag f6c3998d29 xrt: Use struct vive_values for u_compute_distortion_vive 2020-09-30 02:05:05 +02:00
Christoph Haag 29188d681c xrt: Remove all but mesh distortion values from xrt_hmd_parts::distortion
Move vive values to struct u_vive_values in u_distortion_mesh.
Move openhmd values to private struct inside ohmd driver.
2020-09-30 02:05:05 +02:00
Christoph Haag c5209c5ed4 comp: Move mesh generation to comp_renderer init
Use none shader when XRT_DISTORTION_MODEL_NONE is set.
Fall back to none distortion if mesh generation fails or unsupported
distortion model is set.

comp_render init updates comp_settings::distortion_model.

u_compute_distortion_mesh: Don't touch xdev::distortion::preferred,
just add XRT_DISTORTION_MODEL_MESHUV mesh to xdev::distortion::models.
2020-09-30 02:05:05 +02:00
Christoph Haag f82f247c19 comp: Rename distortion.vert to none.vert
After removing the other shaders, it is only used for no distortion anymore.
2020-09-30 02:05:05 +02:00
Christoph Haag bc7a948975 comp: More replacing of binding indices with variables 2020-09-30 02:05:05 +02:00
Christoph Haag 2e7451ca5e comp: Support only mesh and no istortion, remove pano and vive shaders
Also changes hardcoded binding indices into variables to make following the code easier
e.g. when adding new UBOs.
2020-09-30 02:05:04 +02:00
Christoph Haag 80f6fc9039 comp: Replace hardcoded binding indices with variables
Makes it easier to follow when changing code.
2020-09-30 01:30:30 +02:00
Christoph Haag fd883e26bf d/openhmd: Fix distortion_k value ordering
Their order is opposite to the psvr panotools values.
2020-09-30 01:30:30 +02:00
Christoph Haag fb71c71a8c xrt: Replace mesh generator with xdev->compute_distortion()
Each HMD driver now has to implement compute_distortion() which will be called
by the compositor implementation to generate a mesh (usually).

u_distortion_mesh contains implementations for the defaults (panotools, OpenHMD, vive).

Also adds compute_distortion function for Vive distortion

There are differences between OpenHMD and Panotools values, main differences for now:
* psvr has 5 pano coefficients, ohmd has 3
* psvr uses viewport size and lens center in pixels for distortion calculation, ohmd in meter
* psvr uses different distortion scaling than ohmd
2020-09-28 17:04:15 +01:00
Jakob Bornecrantz 2aaa3acfdf st/oxr: Do not destroy native compositor in sub-classed session creation functions
So it's owned by the instance.
2020-09-24 19:07:01 +01:00
Jakob Bornecrantz 6961bf885f st/oxr: Don't create a new native compositor in android session
Spotted by Jarvis.
2020-09-24 19:06:51 +01:00
Christoph Haag ee8fdb45fd d/ns: remove useless assignments 2020-09-22 02:19:13 +02:00
Christoph Haag e5683d4fde comp: remove useless pano ubo from mesh distortion
It was left in as a debug measure, but is more confusing than useful,
especially with northstar directly generating a mesh and vive with its own shader.
2020-09-22 02:19:13 +02:00
Christoph Haag 3c0ae7e61e d/dummy: reduce dummy HMD resolution to 720p 2020-09-21 20:37:28 +02:00
Christoph Haag 31539c800e d/ohmd: Add (OpenHMD) suffix to openhmd driver string 2020-09-21 20:37:28 +02:00
Christoph Haag 3d0235a450 st/prober: Fix build with v4l2 disabled 2020-09-21 20:21:56 +02:00
Jakob Bornecrantz 9ebf1c4d4d st/oxr: Fix warning 2020-09-18 20:51:31 +01:00
Ryan Pavlik 6af00ed8db u/file: Stub out Linux path manip code. 2020-09-18 18:27:46 +01:00
Ryan Pavlik 6ad46cb1b2 build: Be able to build against pthreads4w 2020-09-18 18:25:27 +01:00
Ryan Pavlik 7e600dd244 build: Adjust/fix missing dependencies 2020-09-18 18:25:27 +01:00
Ryan Pavlik 6779b1c0f8 st/p: Fix include of libusb 2020-09-18 18:25:27 +01:00
Ryan Pavlik b71f13c582 st/p: Tighten preprocessor conditionals for non-Linux 2020-09-18 18:25:15 +01:00
Milan Jaros 3f4bcb412e u/threading: Cast result of realloc. 2020-09-18 17:15:33 +01:00
Ryan Pavlik 695a2c1151 u/debug: Silence warnings on MSVC 2020-09-18 17:15:33 +01:00
Ryan Pavlik f7a132e635 u/time: Fix overflow. 2020-09-18 17:15:33 +01:00
Ryan Pavlik 1dffe58952 u/json: Silence warnings on MSVC 2020-09-18 17:15:33 +01:00
Milan Jaros 7685f49adb os/threading: Fix includes on Windows 2020-09-18 17:15:33 +01:00
Milan Jaros 367c01f354 os/time: Provide time functions for Windows 2020-09-18 17:15:33 +01:00
Ryan Pavlik 7c47293c52 os/time: Implement os_nanosleep for Windows 2020-09-18 13:56:34 +01:00
Ryan Pavlik dae3ab3a4f xrt: Be sure to include config headers 2020-09-18 13:56:24 +01:00
Ryan Pavlik a0c8839a71 xrt: Remove un-needed includes of unistd 2020-09-18 13:56:16 +01:00
Ryan Pavlik 54f6aa2166 inc/xrt: Some MSVC and Windows support 2020-09-18 13:56:11 +01:00
Ryan Pavlik 3ff56f4a3c inc/xrt: Add Windows implementations of atomic intrinsics. 2020-09-18 13:56:05 +01:00
Jakob Bornecrantz c411caf0cd st/oxr: Fix return length from oxr_action_get_input_source_localized_name 2020-09-17 23:04:37 +01:00
Jakob Bornecrantz 4a62e88f09 st/oxr: Return identifier name for bindings 2020-09-17 23:04:37 +01:00
Jakob Bornecrantz b6786f5bfc st/oxr: Return controller name for bindings 2020-09-17 15:28:59 +01:00
Jakob Bornecrantz 33713c790c st/oxr: Correctly return sub path for input source 2020-09-17 00:26:12 +01:00
Jakob Bornecrantz 0fc4cdcd0f st/gui: Get the number of samples in a fifo for graph 2020-09-16 17:27:16 +01:00
Jakob Bornecrantz 6a94b1cf80 m/ff: Improve interface 2020-09-16 17:27:16 +01:00
Bart Ribbers 71f912ffc5 Fix compilation on Musl
Without this fix, compilation failed on Musl due to ssize_t being an
unknown type

In file included from ../src/xrt/state_trackers/prober/p_prober.c:15:
../src/xrt/state_trackers/prober/p_prober.h:67:2: error: unknown type name 'ssize_t'
   67 |  ssize_t interface;
      |  ^~~~~~~
2020-09-16 10:44:06 +02:00
Jakob Bornecrantz b624d290d0 m/3dof: Add filter fifos to variable tracking code 2020-09-15 16:41:07 +00:00
Jakob Bornecrantz f7ff6c08ed st/gui: Plot vec3_f32 filter fifos 2020-09-15 16:41:07 +00:00
Jakob Bornecrantz 468f72d62f st/gui: Include ImPlot and Monado-ImGui in gui_imgui header 2020-09-15 16:41:07 +00:00
Jakob Bornecrantz 82ea385c6d imgui: Add igToggleButton function 2020-09-15 16:41:07 +00:00
Jakob Bornecrantz f843c59c37 imgui: Add ImPlot 2020-09-15 16:41:07 +00:00
Jakob Bornecrantz 36ea1825bf imgui: Update to 1.78 2020-09-15 16:41:07 +00:00
Jakob Bornecrantz 3ffa40c628 u/var: Refactor how variables info is passed 2020-09-15 16:41:07 +00:00
Jakob Bornecrantz d5c62f8ccb u/var: Add tracking for filter fifos 2020-09-15 16:41:07 +00:00
Christoph Haag 17ff908041 d/ns: Set XRT_SPACE_RELATION_ORIENTATION_TRACKED_BIT 2020-09-14 16:57:10 +02:00
Christoph Haag 37519dc54d d/dummy: Set XRT_SPACE_RELATION_ORIENTATION_TRACKED_BIT 2020-09-14 16:56:54 +02:00
Christoph Haag ddf3eb5789 st/oxr: Use space graph in global-to-local space transform
This takes care of transforming the velocities.
2020-09-11 19:06:16 +02:00
Christoph Haag 150b7649f3 d/survive: Don't fix up invalid pose 2020-09-11 18:52:01 +02:00
Christoph Haag a664bb22bf d/survive: Update to recent libsurvive git
Rewrite input event handling and add new events from libsurvive.
2020-09-11 18:52:01 +02:00
Christoph Haag c3fbe6eaf8 d/survive: remove unused structs 2020-09-11 18:52:01 +02:00
Christoph Haag 357b47522c d/survive: set relation flags properly 2020-09-11 18:52:01 +02:00
Christoph Haag f41edee4b4 st/oxr: Use space graph resolve result relation flags instead of pure pose relation 2020-09-11 18:52:01 +02:00
Christoph Haag 19acc7be25 st/oxr: Pass actual ViewStateFlags to application with xrLocateViews
These flags are originally set by the driver, then processed by the space graph resolver.
2020-09-11 18:52:01 +02:00
Christoph Haag 2b90b4ea89 st/oxr: Destroy compositor on instance destroy
Fixes direct mode on subsequent instance creation in the same process
when no session was created.
2020-09-11 18:52:01 +02:00
Christoph Haag eb8a304178 ipc: print send and receive errors with ERROR, not DEBUG
These errors lead to unexpected output and should be investigated.
2020-09-11 18:52:01 +02:00
Christoph Haag a884e24b9a aux: Support waiting more than 0.999... seconds in os_nanosleep 2020-09-11 18:52:01 +02:00
Christoph Haag 6133d4cf99 d/survive: Remove out_relation_timestamp_ns 2020-09-11 18:52:01 +02:00
Christoph Haag 844daee844 st/oxr: Check xrLocateViews quaternion only if orientation valid 2020-09-11 18:52:01 +02:00
Christoph Haag 1429d678a0 aux/space: Propagate orientation valid bit through space graph resolve
Invalid poses may be handled more gracefully in the future. For now poses
are not transformed if orientation is not valid, because transforming with
an invalid quaternion will have bad results in any way.

v2: Upgrade poses with valid position but invalid orientation to valid poses
2020-09-11 18:51:58 +02:00
Christoph Haag 6cce04f8d3 aux/space: fix typo: propagate tracked orientation bit properly 2020-09-09 14:51:06 +02:00
Jakob Bornecrantz 8e24dda794 xrt: Remove out_timestamp argument to xrt_device::get_tracked_pose 2020-09-07 23:37:09 +01:00
Jakob Bornecrantz eaffa05a37 xrt: Remove acceleration components from xrt_space_relation 2020-09-07 23:36:34 +01:00
Jakob Bornecrantz 5a4d45bbaa m/base: Remove old space relation functions 2020-09-07 23:33:28 +01:00
Jakob Bornecrantz 855b2005f3 c/main: Use new xrt_space_graph 2020-09-07 23:33:28 +01:00
Jakob Bornecrantz d60cce8977 st/oxr: Use new xrt_space_graph 2020-09-07 23:33:28 +01:00
Jakob Bornecrantz 74690a2278 d/psmv: Rotate angular velocity to be in base space 2020-09-07 23:33:28 +01:00
Jakob Bornecrantz f9905a4007 d/psmv: Use space graphs for poses 2020-09-07 23:33:28 +01:00
Jakob Bornecrantz fe94dec5ea m/space: Space graph functions 2020-09-07 23:33:25 +01:00
Jakob Bornecrantz ca91695722 m/quat: Add math_quat_rotate_derivative 2020-09-07 16:14:46 +01:00
Jakob Bornecrantz 4d85db6051 xrt: Add xrt_space_graph 2020-09-07 16:14:46 +01:00
Moses Turner 0ff1865c2e d/ns: Add version 2 config support 2020-09-07 11:35:24 +01:00
Jakob Bornecrantz ea6374d296 d/dummy: Minor comments 2020-09-06 22:53:10 +01:00
Jakob Bornecrantz 09bcf6c9d2 t/ctl: Fix typo 2020-09-06 21:58:34 +01:00
Jakob Bornecrantz 4f94ee0c91 u/render_timing: Improve debug printing 2020-09-04 13:48:40 +01:00
Christoph Haag 4a1d8b3a41 xrt: Fix vive input defines 2020-09-04 01:46:47 +02:00
Jakob Bornecrantz 787c104339 d/psmv: Use last package timestamp for input changes 2020-09-02 22:08:01 +01:00
Jakob Bornecrantz 328f5d5315 m/base: Add math_quat_invert 2020-09-02 22:07:35 +01:00
Jakob Bornecrantz 511a51b283 m/3dof: Rename to timestamp 2020-09-02 22:07:35 +01:00
Jakob Bornecrantz 8cdfe0e694 m/fifo: Add f64 filter fifo 2020-09-02 22:07:35 +01:00
Jakob Bornecrantz 991c9029c7 m/3dof: Tweak values 2020-09-02 22:07:35 +01:00
Jakob Bornecrantz 736fa81349 m/3dof: Add vars tracking helper function 2020-09-02 22:07:35 +01:00
Jakob Bornecrantz 33f05c7bea m/vec3: Add C++ operators 2020-09-02 22:07:35 +01:00
Jakob Bornecrantz d396117a39 m/vec2: Add C++ operators 2020-09-02 22:07:35 +01:00
Jakob Bornecrantz 2d8a39b731 d/v4l2: Set correct name on variable tracker 2020-09-02 18:36:47 +01:00
Jakob Bornecrantz ffa888a575 d/v4l2: Use different tweaks depending on capture type 2020-09-02 11:57:47 +01:00
Jakob Bornecrantz 6846ab7637 xrt: Add stream capture type 2020-09-02 11:52:59 +01:00
Christoph Haag 330279d330 d/psvr: Set positional tracking bit when tracker is present 2020-09-01 17:03:55 +02:00
Christoph Haag cde94cc8a2 build: Remove libv4l2 dependency from meson
We use the linux/v4l2-common.h header to access v4l devices, not libv4l from v4l-utils.
2020-08-28 12:10:53 +00:00
Pete Black 3f197eeffd t/psmv: Use the same filtering as in PSVR tracker 2020-08-28 11:38:03 +00:00
Pete Black 76a439bd59 t/psvr: Add a functional PSVR tracker 2020-08-28 11:38:03 +00:00
Pete Black 3fdce20afd d/psvr: Only power on front LEDs 2020-08-28 11:38:03 +00:00
Jakob Bornecrantz b3c5bf1517 math: Add a permutation library 2020-08-28 11:38:03 +00:00
Pete Black 0d07c2c343 external: Add Hungarian graph algorithm 2020-08-28 11:38:03 +00:00
Jakob Bornecrantz af540f5ed3 external: Sort libraries in CMakeLists.txt and meson.build 2020-08-28 11:38:03 +00:00
Jakob Bornecrantz d3b224275c u/logging: Fix return of debug_get_log_option_SUFFIX 2020-08-28 11:38:03 +00:00
Pete Black 751fdb2884 u/render_timing: Paranoia 2020-08-28 11:38:03 +00:00
Pete Black 20ee4114b0 xrt: Fix typo in comment 2020-08-28 11:38:03 +00:00
Jakob Bornecrantz 233ca93569 t/ctl: Print devices as well 2020-08-28 11:33:38 +00:00
Jakob Bornecrantz 5c08dc1617 t/ctl: Refactor connection opening 2020-08-28 11:33:38 +00:00
Jakob Bornecrantz 691881f507 t/ctl: Implement device IO toggling 2020-08-28 11:33:38 +00:00
Jakob Bornecrantz 7b9d7091bd t/ctl: Refactor code to make more tidy 2020-08-28 11:33:38 +00:00
Jakob Bornecrantz 4e6a137c62 ipc: Make it possible to toggle inputs on and off 2020-08-28 11:33:38 +00:00
Jakob Bornecrantz 557dacbb02 st/oxr: Special case the any path for pose actions 2020-08-28 10:34:19 +00:00
Jakob Bornecrantz deb5633bf9 d/psmv: Introduce proper grip and aim poses
Correctly rotate the grip pose to follow the spec more closely.
2020-08-27 10:42:05 +01:00
Ryan Pavlik ff603d3acd st/oxr: Add layer type conditionals around depth-image manipulation 2020-08-26 12:28:43 -05:00
Ryan Pavlik 2ac0013e25 st/oxr: Verify that the compositor created can actually do the layer types claimed. 2020-08-26 12:28:35 -05:00
Ryan Pavlik 9d19ab2755 u/misc: Improve docs of calloc macros. 2020-08-26 11:26:46 -05:00
Ryan Pavlik cb26f7255c comp: Use the correct calloc macro 2020-08-26 11:25:43 -05:00
Ryan Pavlik 99fb9fff0d external: Update GLAD again for more extensions 2020-08-26 16:31:56 +01:00
Ryan Pavlik b944b82f3c ipc: Fix build on Android. 2020-08-26 16:31:41 +01:00
Ryan Pavlik 581f59a2eb vk: Add an Android function to the vk_bundle 2020-08-26 16:31:38 +01:00
Jakob Bornecrantz 516212fef4 c/main: Test if a format is supported before adding to list 2020-08-26 14:28:10 +00:00
Jakob Bornecrantz 62fd80ff8d aux/vk: Print a little bit more when failing on usage 2020-08-26 14:28:10 +00:00
Jakob Bornecrantz cac588bbf2 st/oxr: Get maximum layers from the compositor info 2020-08-26 15:25:00 +01:00
Jakob Bornecrantz 1eaf4baf91 c/main: Support 16 layers 2020-08-26 15:25:00 +01:00
Jakob Bornecrantz 1309164303 xrt: Add max layers supported by a compositor 2020-08-26 15:25:00 +01:00
Jakob Bornecrantz 1496262564 xrt: Constify compositor interface 2020-08-26 15:25:00 +01:00
Jakob Bornecrantz 777add8f9e xrt: Tidy some comments 2020-08-26 15:25:00 +01:00
Christoph Haag 8377655128 comp: Handle skipping rendering of infinite cylinder properly
* Setting visibility to none will make the compositor skip rendering this layer
* But do fill in some information in like layer type to ease debugging
2020-08-26 15:59:54 +02:00
Christoph Haag aecfdfc9f9 comp: Fix typo in switch statement 2020-08-26 15:59:54 +02:00
Jakob Bornecrantz 16b9dc13e2 xrt: Correct assert for ipc data type 2020-08-25 14:55:43 +01:00
Jakob Bornecrantz bf9f0e6e39 st/oxr: Use the right depth projection function 2020-08-25 14:55:43 +01:00
Jakob Bornecrantz cd6a237b4a c/client: Add support for depth projection 2020-08-25 14:55:43 +01:00
Jakob Bornecrantz 8356308bf9 c/main: Add support for depth projection 2020-08-25 14:55:43 +01:00
Jakob Bornecrantz efac59a1d8 ipc: Add support for depth projection 2020-08-25 14:55:43 +01:00
Jakob Bornecrantz 9bd725a800 xrt: Add missing xrt_comp_layer_stereo_projection_depth 2020-08-25 14:55:43 +01:00
Christoph Haag 2cd010b65f st/oxr: Verify that projection layer has 0 or view count depth layers 2020-08-24 12:29:47 +02:00
Christoph Haag a9193b0e89 st/oxr: Pass through depth layer to compositor
The compositor does not make use of this layer yet.
2020-08-24 10:30:23 +02:00
Christoph Haag 4f2d421903 st/oxr: Verify depth layer 2020-08-24 10:30:23 +02:00
Christoph Haag 6dc4a1f237 aux/vk: Report appropriate errors on unsupported image usage flags 2020-08-24 10:18:12 +02:00
Christoph Haag 092dddc2da comp: Support Vk and GL depth and depth stencil formats
For now add only the depth formats mandated by OpenGL to maximize the
chances of the Vulkan driver supporting a reasonable set of usage flags
for the formats.
2020-08-24 10:18:12 +02:00
Christoph Haag 5a854fc806 st/oxr: projection layer swapchain NULL check 2020-08-24 10:18:12 +02:00
Jakob Bornecrantz 1914a2ee93 ipc: Tidy 2020-08-21 18:17:18 +01:00
Jakob Bornecrantz fba9f2532c c/client: Fix warning and tidy 2020-08-21 18:17:12 +01:00
Jakob Bornecrantz a4693f3162 st/oxr: Include m_mathinclude.h and tidy includes 2020-08-21 12:18:09 +01:00
Christoph Haag 094a9008c9 comp: Add cylinder layer implementation 2020-08-21 02:24:48 +02:00
Christoph Haag 370f6820aa m: Generalize math_matrix_4x4_quad_model, making scaling a vec3 2020-08-21 02:11:03 +02:00
Christoph Haag 8a17481301 st/oxr: handle subimage rect in submit_cylinder_layer 2020-08-21 02:11:03 +02:00
Christoph Haag 3122e2d073 comp: Use define for number of plane vertices 2020-08-21 02:11:03 +02:00
Christoph Haag fbe390813c vk: Add update_buffer helper function 2020-08-21 02:11:03 +02:00
Christoph Haag cf5596adba comp: Use CLAMP_TO_EDGE for swapchains
Avoids sampling black at the edges of layers.
2020-08-21 02:09:20 +02:00
Christoph Haag 6c084e2cbf build: Add build support for cube, cylinder and equirect layers to meson 2020-08-21 02:09:20 +02:00
Ryan Pavlik 3b8c8ddc1a xrt: Move the android globals functionality to the new android aux lib. 2020-08-19 16:07:00 -05:00
Ryan Pavlik 56dcaf5abf ipc: Some comment improvements. 2020-08-19 16:07:00 -05:00
Ryan Pavlik 7c0df6506b ipc/client: Use Android allocator on client side. 2020-08-19 16:07:00 -05:00
Ryan Pavlik a57507518d aux/android: New aux library, add image allocator for Android 2020-08-19 16:06:30 -05:00
Ryan Pavlik fa34c65ed3 xrt: Make xrt_image_native::size optional.
Not all allocators can supply it.
2020-08-19 16:06:30 -05:00
Ryan Pavlik 640f24438d comp/client: Clean up commented-out code. 2020-08-19 16:06:30 -05:00
Ryan Pavlik c49ccd7b46 comp/client: Improve EGLimage-based swapchain 2020-08-19 16:06:30 -05:00
Ryan Pavlik 3250617dcb comp/client: Use new texture target utility for OpenGL 2020-08-19 16:06:30 -05:00
Ryan Pavlik e48f68deb6 aux/ogl: Add helper header for OpenGL. 2020-08-19 16:06:30 -05:00
Ryan Pavlik 6600e738a3 ipc: Fix loop conditions in loopback allocator 2020-08-19 11:01:49 -05:00
Ryan Pavlik 521de8ecfd comp: Add a URL for sample Android EGL code. 2020-08-19 11:01:49 -05:00
Ryan Pavlik 355ea625dd external/glad: Update to add more extensions 2020-08-19 11:01:12 -05:00
Ryan Pavlik 54149b12b9 st/oxr: Handle the android extension 2020-08-19 11:01:12 -05:00
Ryan Pavlik 430f79a7ca aux/util: Add u_android for global state. 2020-08-19 11:01:10 -05:00
Christoph Haag cd05c86c59 d/ns,rs: Add external slam tracking type 2020-08-19 14:46:55 +02:00
Jakob Bornecrantz 201b5337df ipc: It's okay to send zero handles 2020-08-19 11:45:31 +00:00
Jakob Bornecrantz 019e962f94 ipc: Tidy and better error messages 2020-08-19 11:45:31 +00:00
Christoph Haag 7fb0af90de xrt: Add tracking system type for Hydra 2020-08-19 11:06:28 +00:00
Christoph Haag 23bd6a4377 xrt: Add tracking system type for Lighthouse 2020-08-19 11:06:28 +00:00
Jakob Bornecrantz 8a4db7b3ef st/oxr: Make sure that an identity transform is only inserted when needed 2020-08-18 19:44:26 +01:00
Jakob Bornecrantz 1109bc7cfb st/oxr: Better logging when creating transforms 2020-08-18 19:43:27 +01:00
Jakob Bornecrantz 25c78287a2 st/oxr: Slightly better logging when we fail to transform 2020-08-18 17:06:07 +01:00
Jakob Bornecrantz a3c4cba7f5 st/oxr: Reject bindings that we can't transform 2020-08-18 17:06:07 +01:00
Ryan Pavlik 00abdb358a st/oxr: Proper gles support for Android 2020-08-17 17:30:33 -05:00
Christoph Haag 08ed44b22c d/vive,survive: Manually improve values for Valve Index display
These values are hand picked to provide a less stretchy image.
2020-08-17 22:07:22 +02:00
Christoph Haag 518728156b d/northstar: Set positional tracking bit true when built with RS support 2020-08-17 11:51:38 +00:00
Jakob Bornecrantz 132b0c541d d/rs: Use a thread to get the poses
Tested by moses from Discord.
2020-08-17 11:58:18 +01:00
Christoph Haag 0a667281f9 st/oxr: Print invalid quaternion values in xrLocateView
Gives a hint whether it was zeroed, almost normalized, or not normalized at all.
2020-08-17 12:39:08 +02:00
Ryan Pavlik 54dbb4d128 st/oxr: Use the XR_ERROR_GRAPHICS_REQUIREMENTS_CALL_MISSING code added in OpenXR 1.0.11. 2020-08-14 17:42:19 -05:00
Ryan Pavlik fb48a22cec external: Update OpenXR headers to 1.0.11 2020-08-14 17:37:47 -05:00
Ryan Pavlik 2c126e08ff st/oxr: Handle XRT_ERROR_IMAGE_CREATE_FLAG_UNSUPPORTED from compositor. 2020-08-14 19:58:01 +00:00
Ryan Pavlik 6820a7851d comp/main: Refuse to create a swapchain if protected content bit requested. 2020-08-14 19:58:01 +00:00
Ryan Pavlik 33c20b1a65 inc/xrt: Add a new xrt_result_t code, for when we don't support the specified image flags.
If we don't support protected content (and our compositor doesn't),
we are to error out in a specific way in OpenXR. This permits us to do so.
2020-08-14 19:58:01 +00:00
Jakob Bornecrantz 4b5d25dc33 c/main: Stub in code for cube, cylinder and equirect layers 2020-08-14 19:15:02 +00:00
Jakob Bornecrantz 1292173b5e c/client: Add support for cube, cylinder and equirect layers 2020-08-14 19:15:02 +00:00
Jakob Bornecrantz 4754dcd11b ipc: Add support for cube, cylinder and equirect layers 2020-08-14 19:15:02 +00:00
Jakob Bornecrantz 8846c88eb1 st/oxr: Implement cylinder layer 2020-08-14 19:15:02 +00:00
Jakob Bornecrantz 7eeab2aca6 st/oxr: Implement the layer verification functions 2020-08-14 19:15:02 +00:00
Ryan Pavlik bf37b9d999 comp: Use u_logging in some EGL code. 2020-08-13 17:34:05 -05:00
Ryan Pavlik a6b6ab8e2c ipc: Fix conditionals about handle types. 2020-08-13 17:34:05 -05:00
Ryan Pavlik 1bd2c66aa2 comp: Port to using u_handles 2020-08-13 17:34:05 -05:00
Ryan Pavlik e092345292 aux/vk: Port to using u_handles 2020-08-13 17:34:05 -05:00
Ryan Pavlik 129c1a9ac4 a/util: Add u_handles module. 2020-08-13 17:34:05 -05:00
Ryan Pavlik ab4ceee720 comp: Save/restore the correct texture binding on Android 2020-08-13 17:34:05 -05:00
Ryan Pavlik e52539d1a3 aux/vk: Fix compile time conditionals 2020-08-13 17:34:05 -05:00
Ryan Pavlik f9a613a349 comp: Fix compile-time conditionals 2020-08-13 17:34:05 -05:00
Ryan Pavlik c5d1dec60c comp: Move GLAD loading and extension checking to places with more information.
They will be sure to load the right combination.
2020-08-13 17:34:05 -05:00
Ryan Pavlik 3cfdfbde60 inc/xrt: Tighten requirements for AHardwareBuffer usage.
Needs to be building for platform 26+ (Android 8.0 or newer)
2020-08-13 17:34:05 -05:00
Ryan Pavlik 9087d1c7a9 xrt: Use our generic graphics buffer typedefs all over.
This adds some Android support in composition clients,
and fixes the breakage from 2 commits ago.

Thanks to Jakob for finding my error in an earlier version.
2020-08-13 17:34:05 -05:00
Ryan Pavlik fc73ba0401 comp: Split OpenGL[ES] swapchain types 2020-08-13 17:34:05 -05:00
Ryan Pavlik 475192ec73 xrt: Rename "fd" references to "handle"
This breaks some Android pieces, which will be fixed shortly.
2020-08-12 17:11:42 -05:00
Ryan Pavlik 146218b346 xrt: Some clang tidy fixes.
A few suppressions as well where clang-tidy did the wrong thing.
2020-08-12 17:11:42 -05:00
Ryan Pavlik f1432789ee ipc: Const correctness 2020-08-12 09:51:07 -05:00
Jakob Bornecrantz d27044a18d ipc: Add a disabled loopback allocator 2020-08-12 15:26:43 +01:00
Jakob Bornecrantz a834c9977e ipc: Make it possible to give the client compositor a image allocator 2020-08-12 15:26:05 +01:00