// Use this for initialization void Start() { GameObject cameraAR = GameObject.Find("ARCamera"); ARCamera = cameraAR.GetComponent <Camera>(); markerSettingsMarkerLessActual = null; markerSettingsMarkerActual = null; patternTrackingInfo = new PatternTrackingInfo(); markerSettingsList = markerList.transform.GetComponentsInChildren <MarkerSettings>(); if (markerSettingsList.Length == 0) { existeObjetoDetectar = false; } webCamTextureToMatHelper = gameObject.GetComponent <WebCamTextureToMatHelper>(); #if UNITY_ANDROID && !UNITY_EDITOR // Avoids the front camera low light issue that occurs in only some Android devices (e.g. Google Pixel, Pixel2). webCamTextureToMatHelper.avoidAndroidFrontCameraLowLightIssue = true; #endif webCamTextureToMatHelper.Initialize(); dictionaryAruco = Aruco.getPredefinedDictionary(PropertiesModel.DictionaryId); cornersAruco = new List <Mat>(); idsAruco = new Mat(); }
// Use this for initialization void Start() { webCamTextureToMatHelper = gameObject.GetComponent <WebCamTextureToMatHelper> (); webCamTextureToMatHelper.Initialize(); #if UNITY_EDITOR rot = ARCamera.transform.rotation.eulerAngles; #else Input.gyro.enabled = true; #endif }
// Use this for initialization void Start() { webCamTextureToMatHelper = gameObject.GetComponent <WebCamTextureToMatHelper> (); webCamTextureToMatHelper.Initialize(); }
/// <summary> /// Raises the change camera button event. /// </summary> public void OnChangeCameraButton() { webCamTextureToMatHelper.Initialize(null, webCamTextureToMatHelper.requestedWidth, webCamTextureToMatHelper.requestedHeight, !webCamTextureToMatHelper.requestedIsFrontFacing); }