Application space warp and unity 6 native support

Hello everybody, I’m trying to setup the application spacewarp feature for oculus quest to gain some performance but I can’t figure out how. The meta setup guide is a little bit misleading and i can’t understand how to do it.

As far as i know, until the past versions of the engine, a custom URP version must be downloaded from git but now, from Unity 6000.0.9f1, it should be natively implemented in URP.

I tryied everything explained at this link but i can’t understand how it works, probably i’m missing something.

Can anybody help me to setup the project?

Thanks in advance

Best regard

It’s working on our projects. It works with both the OculusXR plugin and the OpenXR plugin. You do need to have the Oculus SDK in your project and you need to be using the latest URP. You need to do this at some point from a script:

OVRManager.SetSpaceWarp(true);

We do it like this, FWIW:

yield return new WaitUntil(() => OVRManager.OVRManagerinitialized);
OVRManager.SetSpaceWarp(true);

And, of course, you need to enable the feature in your XR plugin settings.

Thanks a lot for your reply, i was totally ignoring the scripting part. Basically, after the project setup all i need to do is to create a script that call that function, right? Do i need to import also any library to call it? Sorry for the dumb question but i’ve never gone so deep with XR coding, i’ve always used just what come out from the box…

Thanks again and best regards

If you use the Meta SDK you can just use that code. If you work on native OpenXR it might take some more steps

Yes. And if you install the Meta XR All-In-One SDK from package manager, then that script will actually compile ;-). (Yes, that is the “library you need to import to call it” from your question.)

I added the missing code and now it works, thanks a lot to everybody! The performance boost is really high…

2 Likes

Thanks for sharing your experience. We have been experimenting with spacewarp as well and noticed Vulkan has a large overhead as compared to gles in our project due to additional copies for each bin, have you seen similar issues?