Is there a way listen for when Vuforia has successfully finished initializing?
I've been poking around the internets , looking thru vuforia documentation, and experimenting in Unity but haven't found a good way to do this which seems odd to me (my apologies if I've missed something). The closest thing I've found is to check if InitState is set to initialized.... but this is read only and not something I can listen for?
VuforiaBehaviour has many actions that can be tied to callback functions;
These are the actions:
public static event Action<VuforiaBehaviour> BehaviourCreated;
public static event Action<VuforiaBehaviour> BehaviourDestroyed;
public event Action AwakeEvent;
public event Action OnEnableEvent;
public event Action StartEvent;
public event Action UpdateEvent;
public event Action OnLevelWasLoadedEvent;
public event Action<bool> OnApplicationPauseEvent;
public event Action OnDisableEvent;
public event Action OnDestroyEvent;
That can be tied like:
Camera.main.GetComponent<VuforiaBehaviour>().OnEnableEvent += OnVuforiaEnabledCallBack;
Or testing the vuforia runtime initialization state:
if (VuforiaRuntime.Instance.InitializationState == VuforiaRuntime.InitState.INITIALIZED)
{
OnVuforiaEnableCallBack();
}