Start a new topic

using app splitting with obb file disables tracking

The problem occurs when I split the apk and generate an obb file.

Starting the App and navigating to the Scene where I use Wikitude everything seams normal. The Camera feed is active and no errors are thrown. The Problem however is Wikitude won't recognize my tracking Images. 

Can the wtc file be my Problem. Wikitude needs it in the Streaming Assets and those are put into the obb. 


I am great full for all help and tips.


Hi Felix,


So everything is running normally when you build an .apk file? Also please provide further details on which SDK version you're using and if this is happening with the sample app as well?


Thx and greetings

Nicola

Hey Nicola,


we are using SDK 8.0.0 and experience the same problem in your sample app.

Building just the apk results in normal behavior but splitting it causes the undesired problem.


Note: we are using ARM64 and exchanged the files as stated in the docu. 

I've just tested the sample application with sdk 8.2.0 and could get following error:

pdf

I've also tested the sample application as is. No settings changed just splitting the Application Binary and the error still comes up (Unity 2018.2.18f1)

Hi, 


It seems that the wtc file could not be found anymore after the apk split.

We'd like to reproduce this behavior internally. Are you using Split Application Binary in Unity, or some other process?


Thank you,

Alexandru


1 person likes this

Hi,


Yes we are using Split Application Binar in Unity.


Thanks for your help.
Looking forward to your response,

Felix

Hi,


Which version of Unity are you using?


Thank you,

Alexandru

Hi Alexandru,


as stated above we are using Unity 2018.2.18f1


Thank you

Hi,


Unfortunately, the solution to this is a bit more complex. The way to work around this problem at the moment is to extract the wtc files from the obb jar and place them in a temporary folder. Then, on the ImageTracker.TargetCollectionResource, you can enable the UseCustomURL property and set the TargetPath to the new path, adding the "file://" prefix.


I've attached a simple script that can be added to the same GameObject as the ImageTracker and does this automatically. This is just an example of how this can be done, but improvements can still be made.


Please let us know if this fixes the issue for you. In the future, we'd like to take care of this internally.


Best regards,

Alexandru

cs

Dear Alexandru,


I have tested this script and it works for the ImageTrackers, as I faced the same issues a few days before release. Thank god!! You saved my life with this script!

Can it be assumed to work with ObjectTrackers as well?

Hi,


I'm happy to hear that this solution worked for you as well. Yes, it should work for ObjectTrackers as well.


Best regards,

Alexandru

Hi Alexandru,


We are having the same issue, after adding the script above, the app just stays blocked with a black screen on startup, no apparent errors on the android monitor. 


We are building with Unity 2021.1.20f1 and Wikitude SDK 9.9

Running on multiple test devices:

    Samsung galaxy S7 with Android version: 7.0 (Black screen)

    Oppo find x3 with Android version: 11 (App closes immediately)


* On the Unity editor all runs and scans fine with and without the script.

* Without the script and with the binary splitting on the app runs but does not scan anything.

* Without the script and binary splitting off, Everything works fine.


Do you have any idea what the problem could be or what further steps we could take to debug this?


Thanks in advance,

Luc

Hi,


The only thing that could be blocking the app would be the request to extract the file, which is happening on line 50 of the original script:


                while (!request.isDone); /* Block until the request is done. */


Can you please add some logs to check if this is indeed where the blocking happens? Aside from that, it would still be useful to post the full logs, as there may be other clues regarding what is actually wrong.


Thank you,

Alexandru

Hi, 


It seems that the wtc file could not be found anymore after the apk split.

We'd like to reproduce this behavior internally. Are you using Split Application Binary mapquest directions in Unity, or some other process?


Thank you,

Alexandru

Hi @Wikitude Technical Support!

Yep, I've tried both of those. They both fail identically.

Please let me know if there's more information I can provide, this has held up testing for several weeks now. It's become the biggest issue for our company.

 

Login or Signup to post a comment