Forum Discussion

🚨 This forum is archived and read-only. To submit a forum post, please visit our new Developer Forum. 🚨
ViktorLinder's avatar
ViktorLinder
Honored Guest
11 years ago

Tuscany demo, Unity build vs. SDK build

When I run the Unity build of the Tuscany demo I experience a lag compared to the SDK build. Both builds are 0.4.2, using the binaries packaged in the .zips. This is not judder, the framerate is 75fps in both cases. It looks consistent with either the orientation sample used for rendering being old or rendered frames being buffered before display.

To see what I'm talking about, stand outside the house (press T to teleport to this position), look at one of the flower pots outside the entrance and shake your head a bit - in the SDK build of the demo the plant remains stable but in the Unity build the plant appears to lag behind the movement.

I'm curious to hear if anyone else is experiencing this?

/Viktor

8 Replies

Replies have been turned off for this discussion
  • g33rt's avatar
    g33rt
    Honored Guest
    Same here. I tried with Unity 4.5 and unity 4.6 beta. I set all build values to those found in de docs, doesn't help. Anyone?
  • same for me, SDK demo run ok but Unity based demos show important judder and immediate nausea...
    Anybody managed to create some content in Unity with DK2 and SDK 0.4.2 and have it running fluently ?
    I am wondering what settings you used for your build as the ones given in the guides do not perform correctly...

    Thanks
  • Can you try the following?

    * Unity 4.5.2f1
    * Direct3D 9
    * Extended display mode
  • * Unity 4.5.3f3
    * Direct3D 9
    * Extended display mode

    Using this setup my scene renders at 60Hz, so its hard to tell if there is a lag. If I set the Rift display to primary the wrong display is picked during start. If I get the time I'll try with the 4.5.2f1 version.

    /Viktor
  • VikotorLinder: is the lag you are talking about the same as what I call 'ghost images' or 'ghost shadows' ?
    What I see in the main Unity demo I am working on (other than Tsucany), it the following: when I look straight without moving, the image is ok. When i rotate my head quickly, I see a faded ghost image "further" than the main image in the direction of head movement, and quickly the main image gets to that point and both fade (=are superposed).
    It looks to me like a prediction issue no ? If I move my head slowly, I don't see that (probably because the gap between ghost and main image is too small).

    Any idea what I can try to make it disappear ?
    I tried D3D9 or DX11, same. FPS is 75Hz (Nvidia Vsync ON). I tried to uncheck TimeWarp in OVERCameraController but no change. I work in extended mode as direct mode never works with my Unity builds.
  • Hm... Could be a difference in how we perceive it, this is what I see:
    Keep your eye fixed on a feature in your scene some distance away. Shake your head a bit back and forth. The image of the feature does not remain stationary (that is, it does remain stationary on the screen), as if you were constantly seeing an old/buffered image or an old orientation sample was used for rendering.

    Rotating your head slowly in a constant movement makes it less noticeable but still uncomfortable since you will experience the view being a couple of degrees off.

    The latency will never be zero of course, but in this case the behaviour is different between the SDK/C++ version of the Tuscany demo and the Unity one.

    /Viktor
  • This seems to be the inverse of my problem as I see the image "in advance" compared to head rotation.

    Let's hope we both find out how to solve that !
  • Thought I'd post an update since I managed to work around this issue: I set the NoVSync flag on the Hmd object:

    OVR.Hmd.GetHmd().SetEnabledCaps(OVR.Hmd.GetHmd().GetEnabledCaps() | (uint)OVR.ovrHmdCaps.ovrHmdCap_NoVSync);


    This removes the lag relative to the non-Unity demos. I should be seeing tearing but I don't, perhaps because my scene renders at ~500fps so consecutive frames are very similar. It is unclear what the Unity "Quality Settings->VSync Count" setting controls when in "Direct HMD Access" mode, I could see no difference when changing it.

    Reading this post by vrdaveb : viewtopic.php?f=37&t=14542#p203439 it sounds like a real fix for this issue might be on the way.