Пример #1
0
        public void SwapBuffers()
        {
            var temp = ActiveFBO;

            ActiveFBO   = InactiveFBO;
            InactiveFBO = ActiveFBO;
        }
Пример #2
0
        public FrameListCreator(int width, int height, Imaging.PixelFormat format = Imaging.PixelFormat.Format24bppRgb, bool drawToFrameBuffer = true, bool needZbuffer = true)
        {
            this.format = format;
            var tex = Texture.Create(width, height, TextureLoader.SelectInternalPixelFormat(format), TextureLoader.SelectPixelFormat(format));

            if (needZbuffer)
            {
                render2tex = new FBOwithDepth(tex);
            }
            else
            {
                render2tex = new FBO(tex);
            }
            if (drawToFrameBuffer)
            {
                tex2fb = new TextureToFrameBuffer();
            }
        }
Пример #3
0
 public DoubleBufferedFBO(Func <Texture> creator)
 {
     ActiveFBO   = new FBO(creator());
     InactiveFBO = new FBO(creator());
 }