Azure / azure-remote-rendering

SDK and samples for Azure Remote Rendering
MIT License
107 stars 39 forks source link

[Remote rendering problem] Quest2: only artifacts showing #113

Closed jelmer3000 closed 1 year ago

jelmer3000 commented 1 year ago

Describe the problem On Quest2, once the rendering has started I only see a square with small blocks/artifacts in the area where the model is placed. I suspect there's a problem with the video feed, but I don't know what. Any insights on what I could try are appreciated.

Here's a videoclip of the problem with the default engine: https://youtube.com/shorts/F59SuC-i54I

jloehr commented 1 year ago

Hey @jelmer3000,

sorry to hear you are experiencing some issues with Azure Remote Rendering. To help you out and to reproduce the issue on our side, we need some more details. Can you provide the following information:

jloehr commented 1 year ago

Ah, I see you have updated your post and provided a video. Awesome!

I see you are using our Showcase sample. Did you upgrade it to Unity 2021 or later? Unfortunately, there's a bug in Unitys built-in render pipeline with later Unity versions: Unity Issue Tracker - MSAA is not applied on Quest 2 using Built-In Render Pipeline and Vulkan That bug creates exactly such artefacts you are seeing.

jelmer3000 commented 1 year ago

Hey thanks for looking into this. My main goal is to just get the showcase example to work on a Quest 2. At first I tried with:

Today I also tried:

In all cases it looks like AA was NOT active, as edges were jerky. But is the MSAA really related the video issues? And in all cases I got the same video artifacts.

All in all what would you recommend setup-wise and Unity versions? In the documentation it says that URP is not recommended because of performance reasons. I could upgrade to Unity 2022, or downgrade.. It would be nice if the showcase just works ;)

jloehr commented 1 year ago

The current version of Showcase released in this repository uses Unity 2020.3 and the built-in rendering pipeline, which is verified by us to work on HoloLens 2 and Quest devices. So, my recommendation would be to stick to that older Unity version.

Using later Unity version and URP should work on Quest with MSAA and Vulkan. Though I've seen bug reports in the past that there have been issues as well. In case it doesn't work as of now, that would be an issue with Unity.

The underlying issue is that on Quest devices MSAA is not enabled on the render target texture, despite Unity's API reporting so. This will create a render target texture format mismatch between what Azure Remote Rendering expects and what Unitys actual texture is using, creating the given visual artefacts.

jelmer3000 commented 1 year ago

Thanks, I got it working with 2020.3 and the built-in rendering pipeline. I also tried 2022.3 but somehow the internet connection wouldn't work there..

It's great that it now works, but it's worrying (for any custom developed app) that I couldn't get it working on recent unity versions with URP.