Commit f49725ac authored by Ben Pastene's avatar Ben Pastene Committed by Commit Bot

Revert "Implemented generic-hand-select over OpenXR"

This reverts commit d1aab4b5.

Reason for revert: To fix compile failures after crrev.com/c/2472913
See https://crbug.com/1138151

Original change's description:
> Implemented generic-hand-select over OpenXR
>
> Implemented generic-hand-select using the MSFT hand interaction
> extension.
>
> Change-Id: I25595dfcf05fd0e23fb7ee9484c333321746fa0e
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2469836
> Reviewed-by: Alexander Cooper <alcooper@chromium.org>
> Commit-Queue: Lachlan Ford <laford@microsoft.com>
> Cr-Commit-Position: refs/heads/master@{#817138}

TBR=rafael.cintron@microsoft.com,alcooper@chromium.org,laford@microsoft.com,phle@microsoft.com

Bug: 1138151
Change-Id: I33d1dcccf893b79e47738447b8c6c8ac01ae72f8
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2473081Reviewed-by: default avatarBen Pastene <bpastene@chromium.org>
Commit-Queue: Ben Pastene <bpastene@chromium.org>
Cr-Commit-Position: refs/heads/master@{#817251}
parent 7ec1f438
...@@ -28,8 +28,7 @@ enum class OpenXrInteractionProfileType { ...@@ -28,8 +28,7 @@ enum class OpenXrInteractionProfileType {
kHTCVive = 4, kHTCVive = 4,
kSamsungOdyssey = 5, kSamsungOdyssey = 5,
kHPReverbG2 = 6, kHPReverbG2 = 6,
kHandSelect = 7, kCount = 7,
kCount = 8,
}; };
enum class OpenXrButtonType { enum class OpenXrButtonType {
...@@ -95,7 +94,6 @@ struct OpenXrControllerInteractionProfile { ...@@ -95,7 +94,6 @@ struct OpenXrControllerInteractionProfile {
// Valve index controller. // Valve index controller.
// HTC vive controller // HTC vive controller
// HP Reverb G2 controller // HP Reverb G2 controller
// MSFT Hand Interaction
// Declare OpenXR input profile bindings for other runtimes when they become // Declare OpenXR input profile bindings for other runtimes when they become
// available. // available.
constexpr const char* kMicrosoftMotionInputProfiles[] = { constexpr const char* kMicrosoftMotionInputProfiles[] = {
...@@ -119,9 +117,6 @@ constexpr const char* kSamsungOdysseyInputProfiles[] = { ...@@ -119,9 +117,6 @@ constexpr const char* kSamsungOdysseyInputProfiles[] = {
constexpr const char* kHPReverbG2InputProfiles[] = { constexpr const char* kHPReverbG2InputProfiles[] = {
"hp-mixed-reality", "oculus-touch", "generic-trigger-squeeze"}; "hp-mixed-reality", "oculus-touch", "generic-trigger-squeeze"};
constexpr const char* kGenericHandSelectInputProfile[] = {
"generic-hand-select"};
constexpr OpenXrButtonPathMap kMicrosoftMotionControllerButtonPathMaps[] = { constexpr OpenXrButtonPathMap kMicrosoftMotionControllerButtonPathMaps[] = {
{OpenXrButtonType::kTrigger, {OpenXrButtonType::kTrigger,
{ {
...@@ -279,12 +274,6 @@ constexpr OpenXrButtonPathMap kHPReverbG2RightControllerButtonPathMaps[] = { ...@@ -279,12 +274,6 @@ constexpr OpenXrButtonPathMap kHPReverbG2RightControllerButtonPathMaps[] = {
1}, 1},
}; };
constexpr OpenXrButtonPathMap kGenericHandSelectButtonPathMaps[] = {
{OpenXrButtonType::kTrigger,
{{OpenXrButtonActionType::kValue, "/input/select/value"}},
1},
};
constexpr OpenXrAxisPathMap kMicrosoftMotionControllerAxisPathMaps[] = { constexpr OpenXrAxisPathMap kMicrosoftMotionControllerAxisPathMaps[] = {
{OpenXrAxisType::kTrackpad, "/input/trackpad"}, {OpenXrAxisType::kTrackpad, "/input/trackpad"},
{OpenXrAxisType::kThumbstick, "/input/thumbstick"}, {OpenXrAxisType::kThumbstick, "/input/thumbstick"},
...@@ -406,31 +395,12 @@ constexpr OpenXrControllerInteractionProfile kHPReverbG2InteractionProfile = { ...@@ -406,31 +395,12 @@ constexpr OpenXrControllerInteractionProfile kHPReverbG2InteractionProfile = {
kHPReverbG2ControllerAxisPathMaps, kHPReverbG2ControllerAxisPathMaps,
base::size(kHPReverbG2ControllerAxisPathMaps)}; base::size(kHPReverbG2ControllerAxisPathMaps)};
constexpr OpenXrControllerInteractionProfile
kHandInteractionMSFTInteractionProfile = {
OpenXrInteractionProfileType::kHandSelect,
"/interaction_profiles/microsoft/hand_interaction",
XR_MSFT_HAND_INTERACTION_EXTENSION_NAME,
GamepadMapping::kNone,
kGenericHandSelectInputProfile,
base::size(kGenericHandSelectInputProfile),
kGenericHandSelectButtonPathMaps,
base::size(kGenericHandSelectButtonPathMaps),
kGenericHandSelectButtonPathMaps,
base::size(kGenericHandSelectButtonPathMaps),
nullptr,
0};
constexpr OpenXrControllerInteractionProfile constexpr OpenXrControllerInteractionProfile
kOpenXrControllerInteractionProfiles[] = { kOpenXrControllerInteractionProfiles[] = {
kMicrosoftMotionInteractionProfile, kMicrosoftMotionInteractionProfile, kKHRSimpleInteractionProfile,
kKHRSimpleInteractionProfile, kOculusTouchInteractionProfile, kValveIndexInteractionProfile,
kOculusTouchInteractionProfile, kHTCViveInteractionProfile, kSamsungOdysseyInteractionProfile,
kValveIndexInteractionProfile, kHPReverbG2InteractionProfile};
kHTCViveInteractionProfile,
kSamsungOdysseyInteractionProfile,
kHPReverbG2InteractionProfile,
kHandInteractionMSFTInteractionProfile};
} // namespace device } // namespace device
......
...@@ -151,13 +151,6 @@ XrResult CreateInstance(XrInstance* instance) { ...@@ -151,13 +151,6 @@ XrResult CreateInstance(XrInstance* instance) {
extensions.push_back(kExtHPMixedRealityControllerExtensionName); extensions.push_back(kExtHPMixedRealityControllerExtensionName);
} }
const bool handInteractionExtensionSupported =
extension_enumeration.ExtensionSupported(
XR_MSFT_HAND_INTERACTION_EXTENSION_NAME);
if (handInteractionExtensionSupported) {
extensions.push_back(XR_MSFT_HAND_INTERACTION_EXTENSION_NAME);
}
instance_create_info.enabledExtensionCount = instance_create_info.enabledExtensionCount =
static_cast<uint32_t>(extensions.size()); static_cast<uint32_t>(extensions.size());
instance_create_info.enabledExtensionNames = extensions.data(); instance_create_info.enabledExtensionNames = extensions.data();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment