Search Unity

OpenVR on Mac and HTC Vive —> Flickering Issues

Discussion in 'AR/VR (XR) Discussion' started by HulloImJay, Aug 25, 2018.

  1. HulloImJay

    HulloImJay

    Joined:
    Mar 26, 2012
    Posts:
    89
    So I recently upgraded to the 2018 MacBook Pro and got the Blackmagic eGPU as well. Seems like this should be ample power for VR on the HTC Vive using OpenVR in Unity.

    I have a project which runs in VR in Unity, but I constantly get flickering issues in the headset — as if it's rendering black off and on, and inconsistently between the two eyes.

    The grey "waiting room" space renders correctly in the headset (no flickering), but everything from Unity flickers. I've updated the firmware for the device and tried every setting I can think of. Valve's SteamVR for Mac is a buggy mess, and there are no Mac VR apps at all I can use to test if the problem is just with Unity or not.

    Does anyone have advice? Anyone have a similar setup which is working?

    Unity 2018.2.2f2
    macOS 10.13.6
     
    TimCoster likes this.
  2. HulloImJay

    HulloImJay

    Joined:
    Mar 26, 2012
    Posts:
    89

    So a BIG part of the problem was that Unity was automatically selecting the wrong GPU! I still get much more flicker than I'd expect, but it's serviceable for development.


    Not sure why Unity would choose a less-powerful GPU, though... I had to manually override this under the Editor preferences (and still haven't figured out how to do it for builds).
     
  3. nicmarxp

    nicmarxp

    Joined:
    Dec 3, 2017
    Posts:
    406
    Hey @Jason-RT-Bond! I have almost that exact problem, but a 2016 MacBook pro and a sonett eGPU with an RX570. My issue is that it flickers black about every 1-2 seconds, and the image stutters a lot. The image I see in the editor looks not to be stuttering.

    When I make a build though, it's perfectly smooth. Also the "waiting room" works perfectly, so I assume it's something with Unity.

    How did you select the GPU? Choosing the device in the preferences didn't make any difference for me.

    I'd be very happy if you could share your finds, I so wanna get creating, but this is annoying :p

    PS: Also I don't get the Post processing stack to work, it shuts of when I start the game, but maybe that's something else.

    EDIT: It seems somehow be performance related, cause if I add a lot of meshes, the flickering and stuttering gets much worse. But even with just a cube and no lights, there seems to be a minimum "bad stuttering" going on.
     
    Last edited: Sep 8, 2018
  4. nicmarxp

    nicmarxp

    Joined:
    Dec 3, 2017
    Posts:
    406
    If you'd like, go ahead and test a build of my simple project. For me, the black flickering is gone, but it's still stuttering a bit when I move my head. Might be due to something that can be optimized. I'm very new to the LWRP, so I'm not sure what to change. Here's the file:
    http://www.nicmar.nu/tmp/flickertest.app.zip (35 Mb)

    What GPU have you got in your eGPU?

    Thanks!

    EDIT: Hmm, I built the VR template with the post processing effects enabled, and I got the same horrible flickering as in the editor. So back to square one. Is this fixable, or do I have to do this on a PC? :(
     
  5. soleron

    soleron

    Joined:
    Apr 21, 2013
    Posts:
    584
    Why oh why did you get a mac for VR development? :(
    I hope things get better for you soon although mac is hardly a good platform for VR. Let alone VR development. On mac 3D, while great for lightweight and medium complexity mobile game visuals, has always been underpowered and unsuitable for demanding 3D work and I am not sure if Metal will be enough to change that.
     
  6. nicmarxp

    nicmarxp

    Joined:
    Dec 3, 2017
    Posts:
    406
    It’s the other way around, I have a great Mac for my everyday job, and I try to cram the VR stuff to work in it.

    I have a PC too which works great for VR, but I prefer developing on the Mac, and anything else Unity related works fine.

    My current path is developing the VR project on the Mac then fine tune and test it on the PC. I only have one Vive so I have to move it back and forth.. :/

    I wish someone with a Mac could tell me their VR setup in Unity worked great :)
     
  7. nicmarxp

    nicmarxp

    Joined:
    Dec 3, 2017
    Posts:
    406
  8. nicmarxp

    nicmarxp

    Joined:
    Dec 3, 2017
    Posts:
    406
    Woho, updating to 10.13.6 helped with the glitching and black flashing in the eyes. Finally!
     
  9. bricefr

    bricefr

    Joined:
    May 3, 2015
    Posts:
    61
    I have the MBP 2018 (Core i9 w/ 32 GB) and a Vega 56 in a eGPU through USB-C. HTC Vive with Unity trough SteamVR. It works great but on high demanding scene you might get some flickering (for ex. with GI and some complex shaders). The same scene on a simple Windows 10 + GeForce 1060 + AMD FX CPU runs perfectly smoothly. So I guess macOS implementation of SteamVR still miss some optimization, also I did notice a lot of improvements those last months. Or maybe is it linked to the Metal implementation made by Unity? Don't know... another question would be: has anybody succeeded to use an Oculus on a Mac for VR development with Unity3D? And if so, are the performances acceptable?
     
    Last edited: Dec 22, 2018
  10. TimCoster

    TimCoster

    Joined:
    May 19, 2016
    Posts:
    16
    I'm using a MBP 2018 i9 32GB + Vega 56 eGPU + OG Vive and I'm experiencing so many bugs with the whole steamVR macOS beta, openVR and Unity combination at the moment that it's basically impossible to develop anything, even for someone as stubborn as me. There's constant black screen flickering in the Unity scene view during play testing and sometimes in the headset as well, SteamVR monitor/compositor apps give all kinds of errors and refuse to quit without using force quit. SteamVR home settings screen doesn't work, at all, SteamVR Unity plugin input window makes Unity crash, etc. etc.. Also all the latest Unity official release versions and alpha, beta versions have the red blue color channels in the vive headset display swapped so are completely unusable!

    Feel like the setup that I have has all the potential to allow for a great VR development experience but at the moment I advise anyone who wants a stable platform for VR development to go Windows (but not by MacOS + Bootcamp + eGPU because your eGPU is probably not going to work with Bootcamp either)