Hello,
I have tried this https://developer.vuforia.com/forum/faq/unity-load-dataset-setup-trackables-runtime
and it gives me error. I saw many people that have this problem and none of them got solution.
Exception in callback: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NullReferenceException: Object reference not set to an instance of an object
The line that breaks is ( the forum adds closing </objectracker> tag automatically ):
ObjectTracker objectTracker = TrackerManager.Instance.GetTracker();
Here is the entire code:
using UnityEngine; using System.Collections; using Vuforia; using System.Collections.Generic; public class DynamicDataSetLoader : MonoBehaviour { void Start() { VuforiaARController.Instance.RegisterVuforiaStartedCallback(LoadDataSet); } void LoadDataSet() { ObjectTracker objectTracker = TrackerManager.Instance.GetTracker(); DataSet dataSet = objectTracker.CreateDataSet(); } }
I'm having the same issue. Is there anyone who was able to solve this issue of the object tracker returning null?