Download

Help with VR regression in 4.18

Hi, I’m trying to troubleshoot a regression with VR in moving from 4.17 to 4.18 and am hoping someone can give me some guidance on where to look. I’ve posted an initial bug report to answerhub [1] but it hasn’t gotten any attention from Epic yet, so I’m trying to see if I can dig into the problem on my own.

Our project has been built to target the Vive and all of that is working great, and we picked up the Samsung Odyssey VR headset to give it a try. I know about the WMP branch of UE4 as a way to get support for Mixed Reality headsets, but for various reasons we need and want to stick with the main UE4 codebase from Epic. Fortunately, Microsoft and Valve have been working together to support Mixed Reality headsets via SteamVR, and in 4.17 this worked really well. Specifically, with steamVR beta installed, we could load up our project and both in the editor and in builds, it worked more or less equally well with a Vive or Odyssey headset.

For unrelated reasons, we’d like to upgrade to 4.18 (there are some non-trivial bug fixes we’d like, in addition to some new features in the forward shader renderer). When we load the project in 4.18, however, VR mode is rendered wrong - it’s as if each eye has a different camera and is looking at a different point in space or something, so you end up not with a 3D image but a headache and feeling sort of cross eyed. We found that this is true with our project, but also in UE4’s VR editing mode, in VR preview mode, etc. We even created a barebones project from the VR template and get the same behavior. So a plain VR project in 4.17 works great, a plain VR project in 4.18 gives the messed up rendering.

As I don’t know when someone from Epic will have time to investigate, I’m desperate enough that I’m going to start digging through the engine source code to see what changed to see if I can narrow down the problem more. But while I’ve spent a modest amount of time in UE4 source, I’ve never looked at any of the code related to VR, so I’m wondering if anyone has some suggestions as to where I should look, especially if the above description triggers any thoughts that might narrow down my search. Really, any suggestions or guidance would be very much appreciated.

Thanks in advance!

[1] [BUG] With SteamVR beta, VR preview is crossed eyed - UE4 AnswerHub

Also, I just confirmed it’s still happening in 4.18.2.

Can you post a project up that has this issue for us to look at? I can not think of anything that might have changed that would affect this.

It sounds like it’s more of a problem with 4.18 + Samsung Odyssey than any specific project.

From AH: “If you create a blank Blueprint-based project in 4.18.1 (not a VR-based template or anything, just a blank prj) and then run it in VR preview, you get the odd rendering problem I’m seeing. If instead you use 4.17.2 and create a blank project and run it in VR preview, the rendering is fine.”

Seems like a bug, did you reported it? Make a very basic level and share it please.

Sure, I’ll do that. But as Alex noted, I literally just open UE4, create a blank BP project (not even using the VR template), and run it in VR preview. In 4.17, it works great. In 4.18, it doesn’t work. On AnswerHub there are other people who have confirmed it as well.

I reported it to AnswerHub, and included the link in my original post, but if there is something else I need to do, please let me know and I’ll do it immediately. Anyway, yes, I’ll make a simple level and share it, but as noted here and on AnswerHub, this appears to happen with all levels and all projects in 4.18 - it happens even with the most basic default project even.

Attached are two projects, one from 4.17.2, the other from 4.18.2. They are tiny because they are literally just the empty default blueprint projects in UE4. Here are the exact steps I followed:

  1. Plug in WMR headset and make sure it’s working
  2. Launch SteamVR [beta] and make sure it’s working
  3. Open Epic Games Launcher
  4. Select “Unreal Engine 4.17.2” and launch
  5. Click “New Project”
  6. Choose Blank Blueprint project
  7. Choose Desktop / Console, Maximum Quality / No Starter Content
  8. Enter name of ‘wmr4172’ and click ‘Create Project’
  9. From the Play dropdown, choose VR Preview and look around with the HMD on

With 4.17.2, everything looks great.

Then, I repeated the process except in #4 I selected 4.18.2 and in #8 I gave it a different name, and in VR Preview things were not rendered properly.

From the reports of other people having this problem, I think this is not specific to any particular WMR model - related posts seemed to describe the same problem on HP and Acer devices too.

Thank you for taking the time to look into it; any help or pointers you can give would be appreciated.

Yep, can confirm this. I have 2 different Mixed Reality Headsets. Both work 4.17.2 and break on 4.18.

I also reported the same issue with the Oculus Rift here: REGRESSION: Using the Oculus Rift with SteamVR plugin instead of Oculus Plugin breaks displayed images - UE4 AnswerHub

@muchcharles (if this is the same user as on discord) was able to track down the issue, and find a solution. He was going to run some tests before submitting a repo.

I added a pull request here that hopefully should fix things: https://github.com/EpicGames/UnrealEngine/pull/4356

I tested on Vive and Rift but not WindowsMR yet.

I tried it on WMR (Samsung Odyssey VR) and can confirm that it fixes the problem. Thank you!

I tried to get to the pull and all I get is a 404. Did you remove it?

Had the link in wrong, it’s https://github.com/EpicGames/UnrealEngine/pull/4356

I’ve gotten my Windows MR headset working again and tested with that as well as Rift.

I have Samsung HMD, works perfect in 14.7 and totally off in 14.8

Any chances Epic will release “quick-fix” for this before 4.19 ?

This is what I found on forum, I’ll test it tonight. Let me know if it works for other owner of Samsung Odyssey. Thanks to VR-EVO

"“For Samsung Odyssey, You have to create a PostProcess Volume and change Screen Percentage to 90%”"

It fixe the crosseye but the aspect ration still off. So in vr it’s really disturbing.
anyone knows how to fix the native screen ratio for vr?

use 4.17.2 for now

Is there way to set exact HMD resolutions with blueprint ? For Samsung Odyssey for example.

To all those saying just use 4.17, 4.17 has a bug where HZB Setup Min can spike and cause 5-50ms of lag depending on the situation. This was never fixed and all the forums end with the solution that is fixed in 4.18, which it is, but you can’t use 4.18 for WMR due to the screen warp. Every seasoned developer who dives into their profiler will end up finding the HZB and realizing they have no options.