예제 #1
0
        // Use this for initialization
        void Start()
        {
            Debug.Log("Camera PreView Texture [" + PreTextureWidth + "," + PreTextureHeight + "]");
            holoeverService = NxrViewer.Instance.GetHoloeverService();
            if (holoeverService != null)
            {
                cameraPreviewHelper = holoeverService.InitCameraPreviewHelper();
            }

            material       = GetComponent <Renderer>().material;
            defaultTexture = material.mainTexture;
        }
예제 #2
0
        // Use this for initialization
        void Start()
        {
            Debug.Log("Camera PreView Texture [" + PreTextureWidth + "," + PreTextureHeight + "]");
            holoeverService = NxrViewer.Instance.GetHoloeverService();
            if (holoeverService != null)
            {
                cameraPreviewHelper = holoeverService.InitCameraPreviewHelper();
            }

            Renderer renderer = GetComponent <Renderer>();

            material       = renderer == null ? null : renderer.material;
            defaultTexture = material != null ? material.mainTexture : null;
#if UNITY_ANDROID
            InitTexture();
#endif
        }