Exemple #1
0
        public override void Commit(CommandList commandList, Texture renderFrame)
        {
            OpenVR.Submit(0, renderFrame, ref leftView);
            OpenVR.Submit(1, renderFrame, ref rightView);

            if (needsMirror)
            {
                var wholeRegion = new ResourceRegion(0, 0, 0, ActualRenderFrameSize.Width, ActualRenderFrameSize.Height, 1);
                commandList.CopyRegion(leftEyeMirror, 0, wholeRegion, bothEyesMirror, 0);
                commandList.CopyRegion(rightEyeMirror, 0, wholeRegion, bothEyesMirror, 0, ActualRenderFrameSize.Width / 2);
            }
        }