Пример #1
0
        private void Form1_KeyDown_1(object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.Q)
            {
                view.IncrementViewScalar(mov * 5);
            }

            if (e.KeyCode == Keys.E)
            {
                view.IncrementViewScalar(mov * -5);
            }

            if (e.KeyCode == Keys.W)
            {
                view.MovePerspective(0, mov);
            }

            if (e.KeyCode == Keys.A)
            {
                view.MovePerspective(mov, 0);
            }

            if (e.KeyCode == Keys.S)
            {
                view.MovePerspective(0, -mov);
            }

            if (e.KeyCode == Keys.D)
            {
                view.MovePerspective(-mov, 0);
            }

            if (e.KeyCode == Keys.X)
            {
                view.Reset();
            }

            OpenEye();
        }