Documentation:UnityAR

From UBC Wiki
Emerging Media Lab
UBC Emerging Media Lab Signature.png
About EML
A collaborative space for UBC faculty, students and staff for exploration of emerging technologies and development of innovative tools and solutions. This wiki is for public-facing documentation for our projects and procedures.
Subpages


Introduction

This page is to document any 'gotchas' regarding AR development in Unity 3D. The goal is to speed up development time and remove some frustrations for users starting out.

Build / Deploy Issues

Application crashes when deploying very simple AR scene to Android:

  1. Go to Build Settings -> Player Settings -> Other Settings.
  2. Under Configurations, Change Scripting Backend to IL2CPP.
  3. Make sure ARM64 is enabled.

Other tutorials that I have encountered do not use Mono for scripting backend. ARCore doesn't work 32bit anymore. Use IL2CPP with 64bit.


Findings come from : https://forum.unity.com/threads/ar-app-crashing-on-my-phone-when-arsession-is-loaded-unity-2019.950843/


Build deploys successfully to Android but no camera:

  • Make sure to check off ARCore under Android. (Project Settings -> XR Plug-in Management -> Enable ARCore).

Image Recognition

  • Unity's built in image recognition works well for flat images (a picture of a mountain, a barcode, a top down view, a coffee coaster, etc.).  It doesn't do well for tracking other objects.  For example, if I took a picture of my bed (even from varying angles and perspectives) it doesn't do well to track.

Related Pages

Are there other EML pages on the UBC wiki or documents on EML's Confluence that should be listed here?

Related Projects

Are there EML projects on the UBC wiki that should be mentioned here?


License

Some rights reserved
Permission is granted to copy, distribute and/or modify this document according to the terms in Creative Commons License, Attribution-ShareAlike 4.0. The full text of this license may be found here: CC by-sa 4.0
Attribution-Share-a-like