Search Unity

Question WebXR Advanced Interaction(Oculus Blackscreen)

Discussion in 'AR/VR (XR) Discussion' started by jocyf, Sep 27, 2020.

  1. jocyf

    jocyf

    Joined:
    Jan 30, 2007
    Posts:
    288
    Hi,
    I created a little video showing my progress using the WebXR Plugin published by Mozilla: https://github.com/MozillaReality/unity-webxr-export

    It has movement & rotation, raycast interaction and teleportation. The original plugin just has grab

    It you have an Oculus Rift or an Oculus Quest with Oculus Link running, you can test it (using Mozilla browser in Windows) here:
    https://www.jocyf.com/Preview/TestAdvancedWebXR/index.html





    Sadly, It works on Firefox on windows but I can't make it work on the Oculus Quest browsers (Oculus / Firefox browsers). Any Idea?
     
  2. yotamshacham

    yotamshacham

    Joined:
    May 3, 2019
    Posts:
    1
    Hi Jocyf, this is working for me on Oculus browser - great work! Would you be willing to give access to your code changes - it would save me a lot of time, I'm researching how to do exactly this (movement, teleportation, etc) and resources are very sparse. Cheers.
     
  3. jocyf

    jocyf

    Joined:
    Jan 30, 2007
    Posts:
    288
    Yeah, there is not much out there but it's easy to make it work once you figure out how to read the sticks in Unity Editor & browser. For me that was the main problem.
    I'll try to submit the project to an Github repository in a few days (in my project there is a lot of code, graphics & scenes not related to this, so I need to clean the project to be able to share it).
     
  4. jocyf

    jocyf

    Joined:
    Jan 30, 2007
    Posts:
    288
    The code has been uploaded here: https://github.com/Jocyf/WebXR-Exporter-Advanced
    You'll get movement, Interaction and Teleport based on the original webXR exporter from mozilla.

    You can test it here (in works in Oculus too besides standalone browser): https://www.jocyf.com/Preview/WebXRAdvanced2019/index.html

    There is a Readme.txt file inside the project if you need more info.

    Regards,
    Jocyf
     
    Last edited: Oct 28, 2020
    Dkp2 and ROBYER1 like this.
  5. ROBYER1

    ROBYER1

    Joined:
    Oct 9, 2015
    Posts:
    1,454
    Thanks for sharing, this is really impressive work especially as WebXR still feels very much under-developed and overlooked
     
  6. De-Panther

    De-Panther

    Joined:
    Dec 27, 2009
    Posts:
    589
    Looks good :)

    This package has a fix for the black screen you mentioned. (If it's the bug that I think it is)
    And there's also some added features like AR support (Headsets and Handheld), Hands API, Hit-Test API, etc...
    https://github.com/De-Panther/unity-webxr-export
     
    Dkp2, jocyf and ROBYER1 like this.
  7. Dkp2

    Dkp2

    Joined:
    Aug 24, 2014
    Posts:
    6
    @De-Panther This looks great, thanks so much for it! The actual fix for the black screen, is it in XRGeneralSettings? I would love to integrate this with @jocyf awesome project.
     
  8. De-Panther

    De-Panther

    Joined:
    Dec 27, 2009
    Posts:
    589
    Most of the issues of black screen were related to the JS side, so changes in the ".jslib" ".jspre" files, and changes in the "webxr.js" file.
    Some lost references of the "SharedArray", some issues regarding the WebGL frameBuffer, and issues when switching between XR sessions.

    Also, @jocyf and I talked in the WebXR discord ( https://discord.gg/Jt5tfaM ), and he already have a version that works with my repo. So now he needs to create a repo for it or update the existing one :)
     
    Gruguir, Dkp2 and ROBYER1 like this.
  9. jocyf

    jocyf

    Joined:
    Jan 30, 2007
    Posts:
    288
    @d
    You can download my unitypackage from here:
    https://www.dropbox.com/s/gvnfxfzrg1k1mw7/WebXRAdvancedDePanther.unitypackage?dl=0

    It has a 100% dependency on last @De-Panther pull. Before importing my pakage, make sure you have installed all webXR @De-Panther content (WebXR Exporter, XR Interactions & his sample scene).
     
    Dkp2, ROBYER1 and De-Panther like this.
  10. De-Panther

    De-Panther

    Joined:
    Dec 27, 2009
    Posts:
    589
    ROBYER1 and jocyf like this.