コード例 #1
0
        private void glControl_Load(object sender, EventArgs e)
        {
            Console.WriteLine("Loading GLcontrol..");
            glControl.MakeCurrent();
            GL.Enable(EnableCap.Texture2D);
            GL.Enable(EnableCap.DepthTest);

            GL.ClearColor(OpenTK.Graphics.Color4.Black);
            GL.Clear(ClearBufferMask.ColorBufferBit | ClearBufferMask.DepthBufferBit);

            InitializeInputTick();
            ActiveCamera.setupGLRenderMatrix();
            Console.WriteLine("GLcontrol is done loading!");
        }
コード例 #2
0
 protected override void OnResize(EventArgs e)
 {
     GL.Viewport(0, 0, Width, Height);
     ActiveCamera     = new OldCamera(Width, Height);
     ActiveCamera.Pos = new Vector3(dragX, dragY, dragZ);
     ActiveCamera.setupGLRenderMatrix();
 }
コード例 #3
0
ファイル: TerrainWindow.cs プロジェクト: rob3ns/WoWFormatTest
 protected override void OnResize(EventArgs e)
 {
     GL.Viewport(0, 0, Width, Height);
     ActiveCamera = new OldCamera(Width, Height);
     ActiveCamera.Pos = new Vector3(dragX, dragY, dragZ);
     ActiveCamera.setupGLRenderMatrix();
 }