Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to load database and failed to create ImageTargetObserver #84

Closed
el-mimoso opened this issue Jan 11, 2024 · 14 comments
Closed

Failed to load database and failed to create ImageTargetObserver #84

el-mimoso opened this issue Jan 11, 2024 · 14 comments
Labels
bug-report Bugs and issues

Comments

@el-mimoso
Copy link

Summarize the bug:
Failed to Failed to load database and failed to Create ImageTargetObserver.

Observed problem
Vuforia is not able to load the databases to create imageTargets therefore there is no tracking of image targets.

Expected result
Vuforia should be able to track images and display the 3D models.

Other observations

  • Works in Android.
  • works in iOS with plane tracker, wont work with image targets.
  • works in unity editor but wont work on ios device.
  • warning in unity console "Invalid AssetDatabase path: /project/path/flutter-unity-view-widget-master/unity/DemoApp/Assets/VuforiaLicense.cs. Use path relative to the project folder."

Reproducible steps
Followed tutorial from here : https://www.youtube.com/watch?v=XKnzW9Z1gU0 at the last step change from ground plane to image target. Using on device database.

Steps to reproduce the behavior:
Followed tutorial from here : https://www.youtube.com/watch?v=XKnzW9Z1gU0 at the last step change from ground plane to image target. Using on device database.
export to xcode
build to physical device
error apears at run time.

Affected Vuforia Engine version:
v(10.19.3)

Affected platform:

  • Workstation OS: MacOS (14.2.1)
  • Platform [Unity][Flutter][XCODE]

Platform version :

  • unity (2022.3.14f1 apple sillicon)
  • flutter (3.13.8)
  • xcode (15.2)

Affected device:

  • Iphone SE 2022
  • OS: IOS 17.2.1

Screenshots / Video Recordings
Captura de pantalla 2024-01-11 a la(s) 5 14 40 p m
Captura de pantalla 2024-01-11 a la(s) 5 21 52 p m

works at unity editor
Captura de pantalla 2024-01-11 a la(s) 5 22 40 p m
issue with iphone
IMG_D087D1673201-1

Affected database
Prueba

Device or platform logs

INFO/AR(20316) Activating observer...
INFO/AR(20316) Activated observer with ID '1'
INFO/AR(20316) Activating observer...SUCCESS
INFO/AR(20316) Starting Vuforia Engine instance...
INFO/AR(20316) Starting camera with profile for iPhone12,8, 800.1
INFO/AR(20316) Starting Vuforia Engine instance...SUCCESS
Creating dataset: Vuforia/Prueba.xml/Trex
Vuforia.Internal.Utility.UnityLogger:LogInfo(String, Object[])
Vuforia.Internal.Utility.Log:Info(String, Object[])
Vuforia.ImageTargetBehaviour:CreateObserverFromDataset(IObserverFactory)
Vuforia.ImageTargetBehaviour:CreateFromSerializedTarget()
Vuforia.ObserverBehaviour:OnVuforiaStarted()
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action)
Vuforia.Internal.Core.Engine:OnStart()
Vuforia.Internal.Core.Engine:Start(Action)
Vuforia.Internal.Core.Engine:Start()
Vuforia.VuforiaBehaviour:AfterVuforiaInitialized(VuforiaInitError)
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action`1, T)
Vuforia.Internal.Core.Engine:InitOnCameraReady()
Vuforia.Internal.ExternalCamera.NullExternalCamera:Init(Func`1)
Vuforia.Internal.Core.Engine:<Init>b__160_0()
Vuforia.Internal.Core.EnginePermissions:OnPermissionRequestFinished(Boolean)
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action`1, T)
Vuforia.Internal.Permissions.<>c__DisplayClass0_0:<CreateRequester>b__0(Boolean)
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action`1, T)
Vuforia.Internal.Permissions.IOSPermissionRequester:Finish()
Vuforia.Internal.Permissions.<RequestPermissions>d__15:MoveNext()
INFO/AR(20316) Creating ImageTargetObserver...
ERROR/AR(20316) Failed to load database 'Vuforia/Prueba.xml'.
ERROR/AR(20316) Creating ImageTargetObserver...FAILED
Vuforia.Internal.Utility.UnityLogger:LogError(String, Object[])
Vuforia.Internal.Utility.Log:Error(String, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action)
Vuforia.Internal.Core.Engine:OnStart()
Vuforia.Internal.Core.Engine:Start(Action)
Vuforia.Internal.Core.Engine:Start()
Vuforia.VuforiaBehaviour:AfterVuforiaInitialized(VuforiaInitError)
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action`1, T)
Vuforia.Internal.Core.Engine:InitOnCameraReady()
Vuforia.Internal.ExternalCamera.NullExternalCamera:Init(Func`1)
Vuforia.Internal.Core.Engine:<Init>b__160_0()
Vuforia.Internal.Core.EnginePermissions:OnPermissionRequestFinished(Boolean)
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action`1, T)
Vuforia.Internal.Permissions.<>c__DisplayClass0_0:<CreateRequester>b__0(Boolean)
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action`1, T)
Vuforia.Internal.Permissions.IOSPermissionRequester:Finish()
Vuforia.Internal.Permissions.<RequestPermissions>d__15:MoveNext()
Vuforia Started
Vuforia.Internal.Utility.UnityLogger:LogInfo(String)
Vuforia.Internal.Utility.Log:Info(String)
Vuforia.Internal.Core.Engine:Start(Action)
Vuforia.Internal.Core.Engine:Start()
Vuforia.VuforiaBehaviour:AfterVuforiaInitialized(VuforiaInitError)
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action`1, T)
Vuforia.Internal.Core.Engine:InitOnCameraReady()
Vuforia.Internal.ExternalCamera.NullExternalCamera:Init(Func`1)
Vuforia.Internal.Core.Engine:<Init>b__160_0()
Vuforia.Internal.Core.EnginePermissions:OnPermissionRequestFinished(Boolean)
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action`1, T)
Vuforia.Internal.Permissions.<>c__DisplayClass0_0:<CreateRequester>b__0(Boolean)
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action`1, T)
Vuforia.Internal.Permissions.IOSPermissionRequester:Finish()
Vuforia.Internal.Permissions.<RequestPermissions>d__15:MoveNext()
Vuforia.Internal.Utility.UnityLogger:LogInfo(String)
Vuforia.Internal.Utility.Log:Info(String)
Vuforia.MonoCameraConfiguration:ConfigureVideoBackground(Matrix4x4)
Vuforia.MonoCameraConfiguration:CheckForSurfaceChanges(Matrix4x4)
Vuforia.CameraController:UpdateCamera(Matrix4x4)
Vuforia.Internal.Core.StateProcessor:ProcessState(IVuState, IDictionary`2, IVideoBackgroundRenderer, IVBAugmentationRenderer, ICameraController, IWorldOriginProvider, DeviceObserver)
Vuforia.Internal.Core.Engine:UpdateState()
Vuforia.Internal.Core.Engine:OnUnityUpdate()
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeDelegate(Delegate, Object[])
Vuforia.Utility.ExtensionMethods.DelegateHelper:InvokeWithExceptionHandling(Action)
Vuforia.Internal.Core.UnityLifeCycleListener:Update()
19  UnityFramework                      0x000000010ba8e898 VuforiaBehaviour_AfterVuforiaInitialized_m496A0E0ABF4D1C1306BB9875824DF84957DF1E44 + 152
35  UnityFramework                      0x000000010a8bce5c _Z146DelegateHelper_InvokeWithExceptionHandling_TisVuforiaInitError_t3C5C78DBB18E9AFDA795BBDF4A176F8C96A5BC88_m27CAC8CEB1E2CACE9FF1499178F59125E8F1C4C7P50Action_1_tF4CAAB52A69FEBB4D629E2D59C8EE77A263FEE43iPK10MethodInfo + 44

Other observation:

  • Changed password.
  • Deleted previous databases.
  • Created new database and targets.
  • upgraded to 10.20 still no luck.
@el-mimoso el-mimoso added the bug-report Bugs and issues label Jan 11, 2024
@ptc-ddowning
Copy link
Collaborator

Hello,

The video referenced is a bit dated, thus the workflow may have changed since Engine's 10.0 release.

Have you tried your device database in the latest version of the Core Samples? This is a more appropriate test to determine if the issue is actually related to a problem with Vuforia Engine and/or the device database.

Thanks,
Vuforia Engine Support

@el-mimoso
Copy link
Author

Hi! Thanks for the feedback.

So I imported the core samples into unity but no luck, the Same error as before. Works at editor, wont work at device.

Error at xcode while running:
Captura de pantalla 2024-01-12 a la(s) 6 25 42 p m

Screencap from device.
image

@ptc-emaggio
Copy link
Collaborator

ptc-emaggio commented Jan 16, 2024

Are the .xml and .dat files present on the device app storage after the app is deployed to the device?

@ptc-epassaro
Copy link
Collaborator

Hello @el-mimoso, the procedure of the tutorial in the description also involves manually changing the Xcode project generated by Unity. Specifically, in the video they remove the Data folder from the Unity-iPhone target.
Are you also applying those changes? If so, please try to build without that change.

The dataset files are stored in the StreamingAssets folder in the Unity project. While building, Unity copies the content of StreamingAssets in Data/Raw in the Xcode project. Removing the Data folder as a member of the Unity-iPhone target results in its content not being accessible by the app, and by Vuforia.

Please let us know how it goes or if you experience other issues.
Thanks!

@el-mimoso
Copy link
Author

Are the .xml and .dat files present on the device app storage after the app is deployed to the device?

Hi @ptc-emaggio thanks for keeping up. In order to see the files inside the app i did xcode > product > archive then in the finder showed the files inside the archive build and found them inside the unity.framework>data>raw>vuforia. I'll attach the folder structure.

image

Hello @el-mimoso, the procedure of the tutorial in the description also involves manually changing the Xcode project generated by Unity. Specifically, in the video they remove the Data folder from the Unity-iPhone target. Are you also applying those changes? If so, please try to build without that change.

The dataset files are stored in the StreamingAssets folder in the Unity project. While building, Unity copies the content of StreamingAssets in Data/Raw in the Xcode project. Removing the Data folder as a member of the Unity-iPhone target results in its content not being accessible by the app, and by Vuforia.

Please let us know how it goes or if you experience other issues. Thanks!

hi @ptc-epassaro thanks for the feedback. I just compiled but same story (also cleaned the build folder via xcode>product>clean build folder. We are planing to use vuforia within a larger app (using the beforementioned tecnologies) but this particular issue is holding us back 😞

image image

@ptc-epassaro
Copy link
Collaborator

@el-mimoso thank you for the detailed update! We will continue looking into this, though unfortunately we were not able to reproduce the issue on our side.
In the meantime, one more thing you could try is to use Unity 2022.3.16f1. Other developers and ourselves have encountered issues with previous versions of the Unity LTS and Xcode 15 which resulted similar consequences.

@el-mimoso
Copy link
Author

el-mimoso commented Jan 18, 2024

I just Downloaded Unity 2022.3.16f1 without luck. Any other sugestion? Maybe I can zip it and share the project folder?

Captura de  pantalla 2024-01-18 a la(s) 3 45 51 p m

IMG_5645

@ptc-emaggio
Copy link
Collaborator

@el-mimoso are you able to reproduce the issue on more than a single device? If yes this would rule out a device configuration/permission problem

@el-mimoso
Copy link
Author

@el-mimoso are you able to reproduce the issue on more than a single device? If yes this would rule out a device configuration/permission problem

You mean in another iphone, if so I can test with some of my buddys phones...

@ptc-emaggio
Copy link
Collaborator

@el-mimoso are you able to reproduce the issue on more than a single device? If yes this would rule out a device configuration/permission problem

You mean in another iphone, if so I can test with some of my buddys phones...

Yes a different iPhone or iPad, same or different model. Just to rule out a permission issue specific to the device

@el-mimoso
Copy link
Author

ion issue specific to the

Built for an ipad same error as before.

Captura de pantalla 2024-01-23 a la(s) 3 38 15 p m

Buuuut find a similar error for a different framework, tried their propossed solution and now it works!
Here is the solution in case somebody else has the same error:
f111fei/react-native-unity-demo#16

IMG_EDECF62128FD-1

Thanks for the feedback and have a nice day!

@PeakPei
Copy link

PeakPei commented Aug 23, 2024

Have you solved it already? I have the same problem

@ptc-thesbyro
Copy link
Collaborator

Hi @PeakPei,

As mentioned by the creator of this issue, they found a workaround - "tried their propossed solution and now it works!
Here is the solution in case somebody else has the same error:
f111fei/react-native-unity-demo#16"

If this did solution did not solve your problem, please create a new ticket and reference this issue for clarity.

Thank you,

@PeakPei
Copy link

PeakPei commented Aug 23, 2024

截屏2024-08-23 20 19 29 截屏2024-08-23 20 19 57 I solved it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug-report Bugs and issues
Projects
None yet
Development

No branches or pull requests

6 participants