ILCCP Stripping removes Object Detection (Unity 6 LTS, 3.16)

Include the following details while filing a bug report (edit as applicable):

  • Host machine & OS version: Mac M4 OS 26
  • Issue Environment : On Device, iPhone 16 Pro, OS 26
  • Xcode version: 26
  • ARDK version: 3.16
  • Unity version: Unity 6 LTS .53f1

Bug reproduction steps:

When building a project using the versions above to device, Unity strips Object detection (on medium and high). Setting the stripping level to low resolves this issue.

MissingMethodException: Default constructor not found for type Niantic.Lightship.AR.Subsystems.ObjectDetection.LightshipObjectDetectionSubsystem+LightshipObjectDetectionProvider

at System.RuntimeType.CreateInstanceMono (System.Boolean nonPublic, System.Boolean wrapExceptions) [0x00000] in <00000000000000000000000000000000>:0

at UnityEngine.SubsystemsImplementation.SubsystemDescriptorWithProvider`2[TSubsystem,TProvider].CreateProvider () [0x00000] in <00000000000000000000000000000000>:0

at UnityEngine.SubsystemsImplementation.SubsystemDescriptorWithProvider`2[TSubsystem,TProvider].Create () [0x00000] in <00000000000000000000000000000000>:0

at UnityEngine.XR.Management.XRLoaderHelper.CreateSubsystem[TDescriptor,TSubsystem] (System.Collections.Generic.List`1[T] descriptors, System.String id) [0x00000] in <00000000000000000000000000000000>:0

at Niantic.Lightship.AR.Loader.NativeLoaderHelper.Initialize (Niantic.Lightship.AR.Loader.ILightshipInternalLoaderSupport loader, System.Boolean isLidarSupported) [0x00000] in <00000000000000000000000000000000>:0

at Niantic.Lightship.AR.Loader.LightshipLoaderHelper.Initialize (Niantic.Lightship.AR.Loader.ILightshipInternalLoaderSupport loader) [0x00000] in <00000000000000000000000000000000>:0

at UnityEngine.XR.Management.XRManagerSettings.InitializeLoaderSync () [0x00000] in <00000000000000000000000000000000>:0

at UnityEngine.XR.Management.XRGeneralSettings.InitXRSDK () [0x00000] in <00000000000000000000000000000000>:0

Hi Tobias,

May I know what you mean by stripping Object Detection? Do you just mean that it does away with the code? I was able to replicate this on both iOS and Android using our Samples package. It built and the home scene opened just fine but when I opened the Object Detection sample it was just a black screen and no camera permission prompt. After setting the level back to Low I got the permission prompt and a camera feed again.

I’ve let our team know about this and I’ll get back to you on why this happens as soon as I have additional info. May I also know why you’re trying to use a higher Strip setting?

Yes it essentially removed the Object detection library so it will not run on device. I used the stripping to reduce app build size and improve runtime performance.

Got it. It’s not clear to me at the moment if ARDK projects require this setting to be at a specific level so I’ve gone ahead and treated it as a bug and raised it to our developers. Please do note that I can’t guarantee if/when this will be addressed

Thank you, Jesus :slight_smile: