예제 #1
0
        private void Draw(PaintEventArgs e)
        {
            _fractal.SurfaceSize = pictureBox1.Size;
            _fractal.Depth       = depth.Value;

            e.Graphics.DrawImage(_fractal.Draw(), new Point(0, 0));
        }
예제 #2
0
        // Render graphics
        protected override void OnRenderFrame(FrameEventArgs e)
        {
            base.OnRenderFrame(e);

            GL.Clear(ClearBufferMask.ColorBufferBit | ClearBufferMask.DepthBufferBit);
            GL.Enable(EnableCap.DepthTest);
            GL.Enable(EnableCap.Texture2D);

            //spritebatch.Begin<TextureProgram>();
            //quadHandler.Draw(spritebatch);
            //spritebatch.End();

            sierpinskiCarpet.Draw(spritebatch);

            //grid.Draw(spritebatch);

            SwapBuffers();
        }