ARDK 2.x -> 3.4 Upgrade: Lightship seems to break Image Tracking

Correct - and sure thing. :slight_smile: I’ve popped a link to a ZIP file of the stripped back project (sans Library & Builds folders) below. I’ve had one of my coworkers make a build from this same ZIP file and he was able to repro the bug with it, so hopefully it’ll be the same for your developers.

https://drive.google.com/file/d/1M_qEPhKKxvJQL5XewB2TDa_SJ0PMP4YG/view?usp=drive_link

Hi Jess,

I have an update for you. The issue is still being looked into but it looks like we’ve been able to narrow it down to the image library not being created with Lightship + ARCore. The cause is still something that’s being investigated since it doesn’t appear to be happening to every user. Can you try the following steps to see if it works for you as a workaround:

  • In PackageManager, remove Lightship ARDK
    • This may cause some ARFoundation class not found issues, that is ok
  • Close Unity and go to your project’s folder
  • Update "com.unity.xr.arcore" entry in Packages/manifest.json to "5.1.4"
  • Delete the Library folder to force a reimport of packages
  • Re-open Unity
  • Select Google ARCore as Android provider in XR Plugin Management
  • Double check the images you’re using and make sure that read/write is still enabled in case it was disabled at some point
  • Reinstall Lightship as a UPM through Package Manager
  • Now, you should be able to change between ARCore and Lightship as providers
  • Next, build with just ARCore and see if that continues to work as it has been.
  • Finally, build with Lightship + ARCore and see if image tracking works now.

The purpose of the last two steps is to see if switching to ARCore without having to uninstall Lightship to do so will properly create the image library and then allow Lightship to use that same image library when building with Lightship

Thanks for the update! I’ve just followed those steps in the non-stripped back project, and tried a few other things. Unfortunately, still no luck. Here are my findings:

  • Following the steps provided, ARCore Image Tracking worked, but with Lightship + ARCore = same issue as previous.
  • Exporting the TrackedImageLibrary when ARCore was set, deleting it, switching to Lightship + ARCore, then reimporting the TrackedImageLibrary = same issue as previous.
  • Creating & assigning a new TrackedImageLibrary whilst the project is set to ARCore, then switching to Lightship + ARCore = same issue as previous.
  • Creating & assigning a new TrackedImageLibrary whilst the project is set to Lightship + ARCore = same issue as previous.
Potentially red herrings, but click here for some other things I noticed

When I build with either provider, even if I’m not referencing Unity’s provided TestReferenceLibrary in the project, I get this warning message:


Screenshot 2024-07-08 120923

When I build my test scene using that TestReferenceLibrary with either provider, the Debug Logs tell me that the image count is 0 (despite being able to see them set in Editor). (The logs say the count is as expected on my own TrackedImageLibraries when tested with each provider)

Also: I never have any issues deleting the Library folder before doing a Lightship + ARCore build, but after doing a Lightship + ARCore build I have to force delete (Shift + Del) the Library folder despite being on an Admin account. Even hitting continue and entering Admin credentials doesn’t let me delete it.
Screenshot 2024-07-08 123738

I’m in my last couple of days with our company, so my coworker @James_Brooks will be your point of contact on this bug report going forward. :slight_smile:

James has just managed to get Image Tracking working in the following dev environment (with a caveat, see :warning: ):

  • Upgraded from Unity 2021.3.3f1 to 2022.3.35f1
  • Installed ARFoundation first
  • It installed ARCore with it
  • Then he installed ARDK 3.6
  • :warning: Enabled BOTH AR Core & Lightship + AR Core at the same time (which I know isn’t meant to be possible).
  • :warning: When I had both providers checked in the ARDK3 beta it broke Semantic Segmentation & Occlusion Extension (see Discord ), so James is now testing to see if our must-have Lightship features are working with these settings. He’ll keep you updated on how this goes, cuz this might be an okay workaround for us in the interim. :slight_smile:

Hi Jess,

Thanks for letting me know. It’s been a pleasure interacting with you on our community forums and Discord. I wish you the best in your future endeavors :slight_smile:

I’m not sure which of you will see this and reply back but what appears to be happening when both are selected is only ARCore is actually taking effect which is also the Lightship features such as semantics and occlusion extension stop working; ARCore completely overwrites Lightship.

Another thing that was suggested was maybe trying to rename the image library asset from its default name in case that’s somehow being used as some sort of magic hardcoded string value somewhere and it’s causing issues

This may also be helpful. A user is having similar issues but in their case, they can remove ARCore after following the steps they provided in their last reply and it seemed to work. It’s similar to what I originally suggested just in a bit of a different order. https://community.lightship.dev/t/ardk-3-6-stops-image-tracking-from-working/4659/3

Hi Jesus,

Thank you for the update. I will be picking up on this where Jess has left off. First of all thank you so much for taking the time to go through this with her and helping us with this bug. I’ve had a speed-walk through with Jess as she has obviously been the one handling the work we’ve been doing with ARDK.

As Jess mentioned, I had previously been able to check both ARCore and Lightship boxes, but that is no longer the case as selecting the Lightship box disables the ARCore one now.

I will take a look through the link and then walk through before testing again.