Esempio n. 1
0
        private void Keyboard_KeyDown(object sender, KeyboardKeyEventArgs e)
        {
            if (e.Key == Key.Escape)
            {
                this.CleanUp();
                this.Exit();
            }

            if (e.Key == Key.Space)
            {
                Leo.SetStereo(!Leo.IsStereoSwitchedOn());
            }

            if (e.Key == Key.F11)
            {
                if (this.WindowState == WindowState.Fullscreen)
                {
                    this.WindowState = WindowState.Normal;
                }
                else
                {
                    this.WindowState = WindowState.Fullscreen;
                }
            }
        }
Esempio n. 2
0
 private void CleanUp()
 {
     Leo.SetStereo(false);
     LGL.DeleteContext(context);
     OpenTK.Graphics.Glu.DeleteQuadric(sphere);
     OpenTK.Graphics.Glu.DeleteQuadric(cylinder);
 }