Log in or register to post comments

Delayed initialization not working as expected

November 10, 2017 - 3:36am #1

(Using Unity 2017.2 + Vuforia 6.5.22)

Not all scenes in this project need Vuforia (and device camera) so I'm trying to prevent Vuforia starting itself and creating "BackgroundPlane" object to all scene Cameras. "Delayed initialization" option is enabled in VuforiaConfiguration but Vuforia is still trying to start itself when the application is started.

How to reproduce:

  1. Create an empty Unity project (3D)
  2. Enable Vuforia in Player Settings -> XR Settings
  3. Enable "Delayed initialization" option in VuforiaConfiguration
  4. Run the project. You'll get an error:

Quote:

Vuforia cannot be started before it is initialized.

Please disable Delayed Initializationin the Vuforia configuration or initialize Vuforia manually with the VuforiaRuntime-class.

Any help how to prevent Vuforia trying to start itself automatically at application startup? Thanks!

Delayed initialization not working as expected

January 29, 2019 - 1:58pm #4

Hello,

The article below isn't completely accurate. If you don't want to start into a Vuforia Engine AR experience, you can just start into a scene that does not have the Vuforia ARCamera in it.

Delayed initialization is only useful if you need to execute code before Vuforia is initialized, e.g. to fetch/uncrypt the Vuforia license key, set a driver library, or update the Vuforia Fusion provider.

https://library.vuforia.com/content/vuforia-library/en/articles/Training/vuforia-fusion-article.html

Thanks,

Vuforia Engine Support

 

Delayed initialization not working as expected

January 25, 2019 - 4:59am #3

Delayed initialization not working as expected

November 10, 2017 - 4:13am #2

Found a workaround for this from Unity forums: https://forum.unity.com/threads/do-not-run-vufory-when-the-application-starts.498351

Quote:

To disable Vuforia in a scene, you need to disable the Vuforia Behaviour.

To disable on the Main Camera, add a VuforiaBehaviour script from Component > Scripts > Vuforia in the menu.

Then disable (uncheck) that script component.

This way it's possible to keep "Delayed initialization" enabled and Vuforia doesn't try to start itself too early (before manual init).

Log in or register to post comments