Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Question Unity OpenXR error: Failed to suggest bindings

Discussion in 'VR' started by itzikpel, Dec 2, 2021.

  1. itzikpel

    itzikpel

    Joined:
    Mar 27, 2015
    Posts:
    19
    Hi,
    I am using Unity OpenXR Plugin 1.3.0
    I added this interaction profiles:

    HTC Vive Controller Profile
    Khronos Simple Controller Profile
    Microsoft Motion Controller Profile
    Oculus Touch Controller Profile
    Valve Index Controller Profile

    We I start the game I'm getting this errors:

    Failed to suggest bindings for interaction profile '/interaction_profiles/htc/vive_controller' with result 'XR_ERROR_PATH_UNSUPPORTED'.
    Failed to suggest bindings for interaction profile '/interaction_profiles/valve/index_controller' with result 'XR_ERROR_PATH_UNSUPPORTED'.

    What am I doing wrong? what am I missing?
    Thanks.
     
    VitN likes this.
  2. NemesisWarlock

    NemesisWarlock

    Joined:
    Jan 21, 2017
    Posts:
    140
    You're doing nothing wrong, That's expected behaviour. Basically it's checking the hardware and going "Hey, this isn't a Vive or Index controller!"
     
    VitN likes this.
  3. itzikpel

    itzikpel

    Joined:
    Mar 27, 2015
    Posts:
    19
    But that's an error, Is it okay to use a build with such errors?

    I also don't have hardware for Microsoft Motion Controller and Khronos Simple Controller...
     
  4. NemesisWarlock

    NemesisWarlock

    Joined:
    Jan 21, 2017
    Posts:
    140
    When Unity Loads the OpenXR Controller Profiles, it asks the OpenXR API to connect to each loaded controller profile.

    OpenXR, In Turn, is basically throwing the equivalent of a NullRef when trying to find that specific controller hardware and saying "Yo, that's not connected!"

    https://www.khronos.org/registry/OpenXR/specs/1.0/man/html/xrSuggestInteractionProfileBindings.html

    This is an error you can safely forget, however, if you want to get rid of it, you *COULD* do some fancy stuff with the Input System to work out what headset is connected, and load the correct controller profile in using the Unity OpenXR plugin API...

    If any other OpenXR experts would like to chip in here?
     
  5. itzikpel

    itzikpel

    Joined:
    Mar 27, 2015
    Posts:
    19
    In that case, could it be that these errors are only fired in editor and not on build?
     
  6. the_real_apoxol

    the_real_apoxol

    Unity Technologies

    Joined:
    Dec 18, 2020
    Posts:
    467
    Technically this is a runtime bug as the runtimes are supposed to all support all of the core interaction profiles and both of those are core interaction profiles. All other interaction profiles are guarded by extensions so the runtime can tell the OpenXR plugin ahead of time that the interaction profile isnt supported and thus we wont send the bindings down for it. I assume you are running against the Oculus runtime which I believe is the only major runtime that does not support the entire core set of interaction profiles at this time.

    That being said the error is harmless and you can ignore it, it just means that the bindings you send for those devices are being ignored by the runtime. It would only matter if those were the only interaction profiles you are sending, in that case you could get no input.
     
    VitN likes this.
  7. jamie_xr

    jamie_xr

    Joined:
    Feb 28, 2020
    Posts:
    62
    The error doesn't seem to be as harmless as suggested. I have it, and it's stopped the input "pointerPosition" "<XRController>{RightHand}/pointerPosition" from reporting the correct positions, always returning (0,0,0). Removing the offending interaction profiles (valve index & htc vive), made the errors go away, and fixed those positions.
     
    sfuseronin likes this.
  8. the_real_apoxol

    the_real_apoxol

    Unity Technologies

    Joined:
    Dec 18, 2020
    Posts:
    467
    That should not be the case, if it is then something else is going on. I will experiment here and see if I can reproduce the same thing.
     
  9. the_real_apoxol

    the_real_apoxol

    Unity Technologies

    Joined:
    Dec 18, 2020
    Posts:
    467
    What version of the input system are you using?
     
  10. the_real_apoxol

    the_real_apoxol

    Unity Technologies

    Joined:
    Dec 18, 2020
    Posts:
    467
    I tried the following configurations with the controller sample and in all cases both the grip and aim positions were tracking properly. If there is a setting or configuration that I missed please let me know. The way the devices and input system works in OpenXR only one device can be active at a time and providing data, so those other devices and bindings should be ignored. In the situation where you are getting invalid data can you also check the `Input Debugger` and see what devices are active ?

    Unity 2023.3.24f1
    OpenXR 1.3.1 / InputSystem 1.0.2 / InputSystem 1.2.0
    OpenXR 1.3.0 / InputSystem 1.2.0
    OpenXR 1.2.8 / InputSystem 1.2.0

    upload_2021-12-7_10-43-32.png

    upload_2021-12-7_10-44-38.png

    upload_2021-12-7_10-45-11.png
     
  11. jamie_xr

    jamie_xr

    Joined:
    Feb 28, 2020
    Posts:
    62
    So now I can't seem to be able to reproduce it.
    My apologies.
     
  12. the_real_apoxol

    the_real_apoxol

    Unity Technologies

    Joined:
    Dec 18, 2020
    Posts:
    467
    No worries, if you see it again and get more info let me know.
     
  13. Nupixo

    Nupixo

    Joined:
    Jan 21, 2016
    Posts:
    5
    This is super helpful, thanks!
     
    Last edited: Dec 10, 2021
  14. colinleet

    colinleet

    Joined:
    Nov 20, 2019
    Posts:
    164
    @the_real_apoxol
    I'm getting an identical and always persistent set of error in the latest 2021.2.7f1 using all of the latest OpenXR packages (OpenXR Plugin 1.3.1, XR Plugin Management 4.2.1, Interaction Toolkit 1.0.0-pre.8) when using Oculus as my OpenXR runtime as well. The error messages always appear at startup around frame 2:
    Error Message.jpg

    The pointer rotation path is the one which is erroring for me as well. This is an issue for me as the default rotations for Oculus and OpenXR are not the same (OpenXR is 90 degrees rotated up as if it's forward vector were pointing in it's transform.up direction unless I use this specific path binding...).

    Pointer Rotation Causing Error On Startup.jpg

    Interaction Profiles Used
    Interaction Profiles.jpg

    Full Error Log Dump
     
    Last edited: Jan 7, 2022
    ROBYER1 likes this.
  15. the_real_apoxol

    the_real_apoxol

    Unity Technologies

    Joined:
    Dec 18, 2020
    Posts:
    467
    The path unsupported errors are just from the Oculus runtime because it doesnt support those interaction profiles properly, but they should just be ignored.

    As for the rotation the `deviceRotation` and `devicePosition` for the Oculus Loader do not match the `deviceRotation` and `devicePosition` for the OpenXR loader. This was a choice made by the Oculus runtime because OpenXR has two poses and the old Oculus loader only had one. The `pointerPosition` in OpenXR is a bit closer to the Oculus loader but still not 100% the same. What is the set up you are using here? Are you using the Oculus loader for Android and the OpenXR for windows?
     
    colinleet likes this.
  16. colinleet

    colinleet

    Joined:
    Nov 20, 2019
    Posts:
    164
    I'm currently stuck in HDRP land so I've only tested it on OpenXR for windows so far. Using the Oculus plugin with the new mapping doesn't provide any rotation, which makes sense from what you said.

    That's good news! Do you know if they have any intention of fixing that? Every oculus developer who has correct controller rotations is currently stuck with have those error messages appearing all the time, and the errors are non-suppressible since they don't happen in game developer controlled code. This seems like a bad design choice from Oculus, especially as it's literally just a Euler rotation from being able to support everyone else's [non-negotiable] standard of having two aim poses...

    Do you know what the exact offset is? All OpenXR developers submitting to the oculus store are going to need to know that since they require the controllers to 100% match their real world size/position/rotation. I originally reported similar [but different] set of problematic offset March here: https://forum.unity.com/threads/unity-support-for-openxr-in-preview.1023613/page-5 (These old photos were using the non-pointer strings and were inconsistent between different OpenXR plugin providers at the time...).

    When I just now took a look the new rotation provided by the pointer string it looks like a 100% match. From the looks of it it's still just the position which is still offset by about half of a controller's bounding box. (Now just in the opposite direction as the link above.)

    Current Offset.jpg
     
  17. the_real_apoxol

    the_real_apoxol

    Unity Technologies

    Joined:
    Dec 18, 2020
    Posts:
    467
    I dont believe they intend to change it at all. The grip and aim positions are all correct by OpenXR standards. The issue is that controller model that is provided in the Oculus Integration package is not properly oriented to match their new grip and aim positions. Proper controller placement in OpenXR is tricky, especially because you dont actually know what controller is in the users hand, just which interaction profile is enabled which may not be the same.
     
    colinleet likes this.
  18. colinleet

    colinleet

    Joined:
    Nov 20, 2019
    Posts:
    164
    Ok that makes a lot of sense, everyone needs to do a small amount of fact checking and manually fixing for their particular variants of the controller's models position is not a lot to ask for each controller model a dev wants in their game.

    Knowing that my previously correct reference was wrong in a new context --- is a lot easier to fix than having the underlying system be inconsistent.
     
  19. jamie_xr

    jamie_xr

    Joined:
    Feb 28, 2020
    Posts:
    62
    Do you know if there is an intention to unify this at all? Since Oculus now runs on OpenXR Backend, why not have 2 poses, and make them match the OpenXR Standard regardless of which plugin is used? I don't use the Oculus Integration package, so for me it's not even about controller rendering. I just want consistency
     
  20. the_real_apoxol

    the_real_apoxol

    Unity Technologies

    Joined:
    Dec 18, 2020
    Posts:
    467
    Unity is pushing an extension called the `Palm Pose` that would help do this, outside of that I dont know of any but we can discuss it with the runtimes.
     
    colinleet likes this.
  21. jamie_xr

    jamie_xr

    Joined:
    Feb 28, 2020
    Posts:
    62
    Interesting, but the OpenXR runtimes all implement the OpenXR standard which means they have to report this data in both poses right? Or am I not correct there.

    I can resolve most of the differences using offsets to approximate the poses on different runtimes, these are just transforms that are used as anchor points that objects can attach to. It looks like this:
    upload_2022-1-13_9-46-15.png

    As you can see I have the rig, then a height offset, and then Head & left/right hands, with aim/grip poses for each, then a whole bunch of offset transforms for each Plugin/Device. In an ideal world I would not need the offsets, but that's where we are right now. For oculus what I do is change the TrackedPoseDriver input mappings so that both aim & grip follow the aim pose reported by oculus plugin mapped to devicePosition - (which actually resembles the pointerPosition/aimpose), then the offset for the grip pose - `[OculusXR] OculusTouch Offset` resolves this and makes the GripPose's offset look like the "grip pose".

    Less than ideal but I can make it work.

    The issue I can't circumvent however is UI input. In the input manager must map to an input action - The input action I setup is called UI/LeftAim - It's mapped to pointer position - I guess I have to remap it just on oculus?

    Surely there has to be a desire from Unity to unify these inconsistencies? Or is the attitude that, most users should only want to use one plugin?
     
  22. the_real_apoxol

    the_real_apoxol

    Unity Technologies

    Joined:
    Dec 18, 2020
    Posts:
    467
    For the UI/LeftAim there is a workaround but it requires a copy of the OpenXR Oculus Interaction Profile to be made that changes the names of things due to a naming conflict with the Oculus package. Unfortunately we cannot fix this until 2.0 of the openxr plugin as it is considered a breaking change. However with this interaction profile it will allow you to add specific bindings for the controlls in UI/LeftAim so you can bind to OculusController with devicePosition and OculusControllerOpenXR for the position. I included the workaround script here.

    The binding fix is to stop using XRController and call out the specific bindings.

    <OculusControllerOpenXR>{LeftHand}/pointerPosition
    <OculusController>{LeftHand}/devicePosition

    ... Any other interaction profile bindings here ...
     

    Attached Files:

  23. jamie_xr

    jamie_xr

    Joined:
    Feb 28, 2020
    Posts:
    62
    So how would this sit with other devices? I try not to use device specific bindings, and try to use <XRController> where possible, so it can be cross platform, Do you think I can bind the this aim action to all 3. Oculus controller from oculus, Oculus controller from OpenXR, and XR Controller as a catch all ?

    Also what's the ETA on OpenXR 2.0?
     
  24. the_real_apoxol

    the_real_apoxol

    Unity Technologies

    Joined:
    Dec 18, 2020
    Posts:
    467
    With OpenXR the recommendation is to use specific device bindings, because XRController is just a macro that expands to bindings within all the selected interaction profiles, it has no runtime benefit with OpenXR. This means it is only a shortcut for entering bindings and not a means of providing cross platform support. The idea is to be very specific about which controls you want mapped to which actions per device to ensure the best gameplay on each device. Remember that the runtime is taking care of converting controller bindings from one device to another in the event that you did not configure bindings for particular device, not unity, so you only need to specify bindings for the devices that you want to specifically configure and let the runtime do the rest. This is how OpenXR provides future proofing your games and applications since they would not need to be recompiled for newer hardware that was not known of at the time the game was created, the runtime just needs to provide a map of controls from the devices that were configured to ones it knows about.

    The current plan for OpenXR 2.0 will be later in 2022 and will require unity 2022+, but its early so any of that could still change. In 2.0 we are moving even more towards specific device bindings and away from XRController.
     
    colinleet likes this.
  25. colinleet

    colinleet

    Joined:
    Nov 20, 2019
    Posts:
    164
    @jamie_xr Could you please please publish the Left/Right hands you have pictured right here as a prefab? That alone would save a hundred+ fellow game developers about 20 tickets trying to test/get all of the offsets from random online sources... (If you have all of them, and even if you only have some of them we could collectively still open source all of the other offsets here!)
     
    Last edited: Jan 19, 2022
  26. jamie_xr

    jamie_xr

    Joined:
    Feb 28, 2020
    Posts:
    62
    I don't actually have the offsets yet, they are all just 0,0,0 I was just demonstrating how I set it up, so when we come to test our game on each device we can play with offsets in there to find an offset that feels correct.
     
  27. LeFx_Tom

    LeFx_Tom

    Joined:
    Jan 18, 2013
    Posts:
    86
    In 2020.3 LTS, we get the suggested bindings error too...but for us, it seems a blocking error.
    The engine gets stuck in Play-Mode and VR is not initialized fully, when we include profiles, that are not being used (e.g. Vive Controller and Oculus Touch)

    Anyone else still getting that?
     
    ROBYER1 likes this.
  28. ash_at_unity3d

    ash_at_unity3d

    Unity Technologies

    Joined:
    Jan 9, 2020
    Posts:
    41
    @LeFx_Tom what version of the OpenXR plugin are you using?
     
  29. LeFx_Tom

    LeFx_Tom

    Joined:
    Jan 18, 2013
    Posts:
    86
    Correction:

    We have been running on 2020.3.25f and 1.3.0 plugin

    Now we are running on 2020.3.26f and 1.3.1 plugin - and things seem to work?
    We're still investigating
     
    Last edited: Feb 9, 2022
  30. ash_at_unity3d

    ash_at_unity3d

    Unity Technologies

    Joined:
    Jan 9, 2020
    Posts:
    41
    @LeFx_Tom Interesting.

    Let me ask around on the OpenXR team, see if anything's changed.1.3.1 did have a couple of input changes, but nothing that should have been binding related.
     
  31. KineticBen

    KineticBen

    Joined:
    Jul 19, 2021
    Posts:
    8
    Any updates on this?
     
  32. emrys90

    emrys90

    Joined:
    Oct 14, 2013
    Posts:
    752
    I would also like a fix for these error messages. While I understand they are harmless, they do clutter logs and having fake errors being reported will lead to instances that you overlook real errors in the console because you are now conditioned to ignore errors.

    I tried doing something like this in Awake:
    OpenXRSettings.Instance.GetFeature<HTCViveControllerProfile>().enabled = false;
    OpenXRSettings.Instance.GetFeature<ValveIndexControllerProfile>().enabled = false;
    But that returns an error saying you cannot disable them once OpenXR has been started.
     
  33. MigolasUnity

    MigolasUnity

    Joined:
    Dec 13, 2021
    Posts:
    2
    No this XR_ERROR_PATH_UNSUPPORTED
    with this configutation:
    unity 2021.2.0f1
    XR plugin Management 4.2.0
    Open XR plugin 1.2.8
    Oculus XR plugin 1.10.0
    Input system 1.2.0
    but if i update to
    unity 2021.3.1f1
    XR plugin Management 4.2.1
    Open XR plugin 1.3.1
    Oculus XR plugin 3.0.1
    Input system 1.3.0
    this error appears.
     
    Last edited: Apr 27, 2022
  34. fendercodes

    fendercodes

    Joined:
    Feb 4, 2019
    Posts:
    189
    Bump. There should never be an error that developers are asked to just ignore. We have thousands of players in our game and these sorts of errors will clog up our diagnostics.
     
  35. simon_zappar

    simon_zappar

    Joined:
    Mar 23, 2018
    Posts:
    16
    I'm still confused about how this "should" work. Say I want to support Vive and Oculus Touch - I add them both in the interaction profiles section and set up specific bindings for them individually. But then say the Oculus runtime does now support and re-map the Vive interaction profile, it would presumably be the "Vive-specific" bindings that Unity would use, even though the runtime has remapped them to the Touch controllers. Do OpenXR runtimes have the concept of a preferred profile to handle this case?
     
  36. Chris-Mxx

    Chris-Mxx

    Unity Technologies

    Joined:
    Nov 10, 2022
    Posts:
    13
    Hi simon_zappar, the OpenXR runtimes don't follow a preferred profile when matching a device to an interaction profile. Instead, the runtime will match the best possible profile to the device. If multiple profiles can be matched as best as any other, then the runtime may pick any of those.