Azure / azure-remote-rendering

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

[Remote rendering problem] Can't pass trough the ConnectToRuntime step on HoloLens 2, but it works on Unity #28

Closed Cyhzault closed 3 years ago

Cyhzault commented 3 years ago

Describe the problem

I'm using Azure Remote rendering for an industrial project i'm working on. I started with version 0.1.78 and followed the tutorial as described in the online documentation. I recently upgraded my project to the version 1.0.1 and incorporated some of the features from the Showroom app. The project is working perfectly fine on Unity Editor (2019.4.19f1), I successfuly managed to connect and interact with a custom remote model as Intented.

The issue occurs only on HoloLens 2 after deploying both on ARM and ARM64 : 1 - Application passes Identification step 2 - Application launches or finds a remote session 3 - When the session is ready, the application is failing to pass the ConnectToRuntime step.

The ConnectRuntimeToRemoteSession function is called : image

Here is the function that receive the status update event :

image

The logs are the following :

As read on the documentation i'm keeping the ARRSessionService Updated in the LateUpdate() image

I'm really surprised about this bug as i didn't encounter any issue on Unity and as it used to work on HoloLens before the upgrade.

Any clues about what is causing the issue ?

Thanks for your help

Cyhzault commented 3 years ago

Hello there,

In the end, I managed to make it works by updating to version 1.0.4 and re-importing all my librairies. I also increased the delay between each of my requests attempts.

I don't really know what causes the failure in the first place and I'm still surprised about the difference of behaviour between HoloLens and Unity.

ChristopherManthei commented 3 years ago

Hi Cyhzault,

Glad to hear you could solve your problem. In general, you should only try to connect again once the previous attempt has failed. This can be observed by either the returned async task completing or the connection status changing back to disconnected.

The difference between Unity and HoloLens is mostly caused by Unity's cache. We have had problems with Unity's cache being corrupted after upgrading packages, see compile failures when compiling Unity samples. Normally this results in compile errors but the same steps should be taken if things suddenly stop working for any clear reason to rule out Unity's cache. So after each major upgrade, clear the project's cache folders as described in the link and build the project into an empty folder.

Cheers, Christopher

Cyhzault commented 3 years ago

Hi Christopher,

Indeed, I'm waiting for the previous attempt to fails before trying again. You must be right, I think it was only a silent cache Issue, i will keep that in mind for the future upgrades.

Thanks for your feedback. Problem solved, I'm closing the issue.

Regards, Alexis.