Forum Discussion

🚨 This forum is archived and read-only. To submit a forum post, please visit our new Developer Forum. 🚨
Forux's avatar
Forux
Explorer
2 years ago

After v55 dynamic resolution broken

Hi,

After 55 update of oculus integration for Unity

Variable OCULUS_XR_VULKAN_DYNAMIC_RESOLUTION starts to be false

On 54 version are no such problem

Because of that Dynamic Resolution stopped working.

Unity 3D version is 2022.4.3f1
Oculus XR plugin 4.0
Oculus Integration 55.0

Do you know any workarounds?

9 Replies

Replies have been turned off for this discussion
  • Hi Forux,

    I was also having this problem, I managed to get around it by modifying line 219 of OVRManagerEditor.cs.

    you need to change 

    if (apis.Length >= 1 && apis[0] == UnityEngine.Rendering.GraphicsDeviceType.Vulkan)

    To

    if (apis.Length >= 1 && apis[0] != UnityEngine.Rendering.GraphicsDeviceType.Vulkan)

    That seemed to do the trick for me, hope it helps!

  • It can help in Editor, but then in OVRManager.cs itself, you will get next:
    Where OCULUS_XR_VULKAN_DYNAMIC_RESOLUTION false, it will not work, I tried to change it manually, but I am sure OCULUS_XR_VULKAN_DYNAMIC_RESOLUTION  must be true and if it is not - it is a problem

    I also checked that OCULUS_XR_VULKAN_DYNAMIC_RESOLUTION is present only in 3.3 XR plugin, Oculus XR plugin version 4.0 does not set it up

    #if !OCULUS_XR_VULKAN_DYNAMIC_RESOLUTION || UNITY_2020
            if (enableDynamicResolution && SystemInfo.graphicsDeviceType == GraphicsDeviceType.Vulkan)
            {
                Debug.LogError("Vulkan Dynamic Resolution is not supported on your current build version. Ensure you are on Unity 2021 + with Oculus XR plugin v3.3.0+");
                enableDynamicResolution = false;
            }
    #endif

     

  • I tried the Oculus XR plugin v3.3.0 - also does not work

  • ronjart's avatar
    ronjart
    Start Partner

    I have the same issue. I'm on Unity 2022.3.1f1 LTS and Oculus XR plugin 4.0

  • I had the same issue, I was able to work around it by manually adding the missing defines to asmdefs in oculus plugin:

     

    • Forux's avatar
      Forux
      Explorer

      KrzysztofWrona wrote:

      I had the same issue, I was able to work around it by manually adding the missing defines to asmdefs in oculus plugin:

       


      And you manage to get dynamic resolution working in Headset?

      • KrzysztofWrona's avatar
        KrzysztofWrona
        MHCP Member

        I was only able to get it to work in headset on LTS 2022, in LTS 2021 it doesn't seem to work

  • Via https://developer.oculus.com/downloads/package/unity-integration/

    "Enabling Dynamic Resolution while using Vulkan will fail, throwing an error saying that you are on an unsupported Unity or Oculus XR plugin version. If you have a compatible version you can fix this by opening OVRManagerEditor.cs and OVRManager.cs files and removing all instances of !OCULUS_XR_VULKAN_DYNAMIC_RESOLUTION."

     

    v54 is working for me, but it is scaling down my app "too little, too late". Not usable for me.

  • What worked for me is:

    having the URP asset render scale set to 1 -> that makes OVR dynamic resolution work (I also noticed that min and max value have to be different)

    Setting URP render scale to something other than 1, will cause dynamic resolution to stop working and to be fixed at the value you set.