private void SetupRenderTexture()
        {
            SetupEyeRenderTextureDescription();

            var newLeft  = new RenderTexture(_eyeRenderTextureDesc);
            var newRight = new RenderTexture(_eyeRenderTextureDesc);

            leftCam.targetTexture  = newLeft;
            rightCam.targetTexture = newRight;

            CardboardManager.SetRenderTexture(newLeft, newRight);
        }
Ejemplo n.º 2
0
        private void SetupRenderTexture()
        {
            eyeRenderTextureDesc = new RenderTextureDescriptor()
            {
                dimension       = TextureDimension.Tex2D,
                width           = Screen.width / 2,
                height          = Screen.height,
                depthBufferBits = 16,
                volumeDepth     = 1,
                msaaSamples     = 1,
                vrUsage         = VRTextureUsage.OneEye
            };

            RenderTexture newLeft  = new RenderTexture(eyeRenderTextureDesc);
            RenderTexture newRight = new RenderTexture(eyeRenderTextureDesc);

            leftCam.targetTexture  = newLeft;
            rightCam.targetTexture = newRight;

            CardboardManager.SetRenderTexture(newLeft, newRight);
        }