From cb12fb78cad4be5fa18edf0de1f8891cd97a9bed Mon Sep 17 00:00:00 2001 From: Peter Kim Date: Sun, 16 May 2021 03:33:10 +0900 Subject: XR Controller Support Step 1: Internal Abstractions for OpenXR Actions Adds internal API for creating and managing OpenXR actions at the GHOST and WM layers. Does not bring about any changes for users since XR action functionality is not yet exposed in the Python API (will be added in a subsequent patch). OpenXR actions are a means to communicate with XR input devices and can be used to retrieve button/pose states or apply haptic feedback. Actions are bound to device inputs via a semantic path binding (https://www.khronos.org/registry/OpenXR/specs/1.0/html/xrspec.html#semantic-path-interaction-profiles), which serves as an XR version of keymaps. Main features: - Abstraction of OpenXR action management functions to GHOST-XR, WM-XR APIs. - New "xr_session_start_pre" callback for creating actions at appropriate point in the XR session. - Creation of name-identifiable action sets/actions. - Binding of actions to controller inputs. - Acquisition of controller button states. - Acquisition of controller poses. - Application of controller haptic feedback. - Carefully designed error handling and useful error reporting (e.g. action set/action name included in error message). Reviewed By: Julian Eisel Differential Revision: http://developer.blender.org/D10942 --- source/blender/python/intern/bpy_app_handlers.c | 1 + 1 file changed, 1 insertion(+) (limited to 'source/blender/python/intern') diff --git a/source/blender/python/intern/bpy_app_handlers.c b/source/blender/python/intern/bpy_app_handlers.c index 8ecee9b3f2e..a0b543097e6 100644 --- a/source/blender/python/intern/bpy_app_handlers.c +++ b/source/blender/python/intern/bpy_app_handlers.c @@ -74,6 +74,7 @@ static PyStructSequence_Field app_cb_info_fields[] = { {"version_update", "on ending the versioning code"}, {"load_factory_preferences_post", "on loading factory preferences (after)"}, {"load_factory_startup_post", "on loading factory startup (after)"}, + {"xr_session_start_pre", "on starting an xr session (before)"}, /* sets the permanent tag */ #define APP_CB_OTHER_FIELDS 1 -- cgit v1.2.3