My perception from Unity’s demos of AR Foundation, is that it is a single codebase that can handle basic AR across almost any platform. They demo AR Foundation on hololens, but have no tutorials that I can find on how to recreate it. Do you still need MRTK to use AR Foundation with hololens, if so how can I use that same project to build for iOS/Android without build errors when switching platforms?
If I don’t need MRTK how do I handle the hololens cursor and gestures?
You can test it in preview form in 2019.3b5+ using the latest verified version of ARFoundation (2.1.4) and the preview version of the Windows MR package. Easiest way to get this is to edit your project’s manifest.json to include this line:
Are there any examples how to set up a very basic scene with AR Foundation image tracking on HoloLens?
I have set up the basic scene and it is working as expected on iOS + Android. I can see the content tied to image targets and all of the content that is just placed in the scene.
I have included the Windows MR 2.0.3-Preview package to the project. The project builds for HoloLens, but it doesn’t ask for camera access etc. The content that is not tied to image targets is working as expected. It all stays in place when walking inside the room. The image targets are not working on the HoloLens build.
I’m familiar with these examples, but I’m looking for any HoloLens specific setting / tweak. The image target test scene working with Android + iOS is not working on HoloLens. I’m simply placing a simple cube on top of the image target by using the cube as the instantiated prefab. The problem seems to be that the HoloLens is not even asking for the camera access permission although I have enabled webcam access in the capabilities. So it seems I’m missing something else in the setup.
Or should the preview version even support image targets on HoloLens at this stage?
One problem though: When I install any of the “new” XR packages (Windows MR, ARCore, ARKit) it prevents any “legacy” XR (e.g. Google Cardboard) from working. (Unity 2019.3.0b6) Are there plans to promote Google Cardboard to non-legacy XR status? My app has to support both AR and VR in the same build.
The Hololens package uses a new stereoscopic rendering path which is incompatible with the legacy one. That means that currently, you cannot mix Cardboard (which uses the legacy path) and the new Hololens package (which uses the new one).
It’s fine to mix the ARCore XR Plugin or ARKit XR Plugin and Cardboard, but once you add the new Hololens package to the mix it disables the legacy stereoscopic pipeline.
I tried Unity 2019.2 + ARFoundation 3.0.1 + ARSubsystem 3.1.0 (preview2) with the HoloLens2 and the
ARSessionState.CheckingAvailability function to know if it’s supported. It is not.
In my experience ARFoundation 3.0.1 does not support HoloLens2.
Maybe there is a way to make it work in Unity 2019.3 but MRTK does not support 2019.3.
I was able to add it with an entry in the json.
But now my app shows nothing. There should be a cube on my HoloLens 1.
Is there a general “how to” for scene and project setup on HoloLens?
Is ARFoundation supposed to run with the HoloLens 1? I am trying all kinds of settings but only get a black screen with the cursor visible. There is also no splash screen.