void Awake() { VuforiaAbstractBehaviour vuforia = FindObjectOfType <VuforiaAbstractBehaviour>(); vuforia.RegisterVuforiaInitErrorCallback(OnInitError); // Get the UI Canvas that contains (parent of) the error text box if (errorText) { errorCanvas = errorText.GetComponentsInParent <Canvas>(true)[0]; } }
void Awake() { mPopUpMsg = GetComponent <SampleInitErrorHandler>(); if (!mPopUpMsg) { mPopUpMsg = gameObject.AddComponent <SampleInitErrorHandler>(); } // Check for an initialization error on start. VuforiaAbstractBehaviour vuforiaBehaviour = (VuforiaAbstractBehaviour)FindObjectOfType(typeof(VuforiaAbstractBehaviour)); if (vuforiaBehaviour) { vuforiaBehaviour.RegisterVuforiaInitErrorCallback(OnVuforiaInitializationError); } }
void Awake() { VuforiaAbstractBehaviour vuforia = FindObjectOfType <VuforiaAbstractBehaviour>(); vuforia.RegisterVuforiaInitErrorCallback(OnInitError); }