When I try to use both Azure Spatial Anchors (ASA) and Vuforia in a Unity project, I get a "NullReferenceException: Object reference not set to an instance of an object" error in the initialization of Vuforia.
- It does work in Unity Play mode, but crashes in HoloLens
- It does not matter whether I use delayed Initialization or not
- My versions are Unity 2020.3.24f1, Vuforia 10.3.2, Azure Spatial Anchors SDK Core/Windows 2.12.0
When I remove Azure Spatial Anchors SDK Core/Windows and include ARFoundaton, it also crashes with the same error. I do see some switching of arfoundation versions in the VuforiaConfiguration, so likely it is related to ARFoundation, which is also used by the Azure anchors.
I tried updating Azure anchor versions, through package manager. This did upgrade the internal ARFoundation version of VuforiaConfiguration, but that did not fix it. When it indicates version 4.1.9 when without Azure anchors it seems to work, but this is reset as soon as I include anchor Azure anchors again and start building. The versions it had where it did not work are 4.0.12 (old Azure Anchors package) 4.1.13 (new latest Azure anchor package)
I did not yet upgrade the Vuforia version, because this is a breaking update always and takes considerable time.
We really need both functionalities, so I hope there is a solution to this. Thanks
I am also trying to find a solution to this problem. I have identified it. Vuforia and ASA need the camera both but vuforia monopolizes it so we have to switch the use of the camera between these two SDK. If you have an idea tell me ;)