public MouseControl(PoincareWindow poincareWindow)
        {
            PoincareWindow = poincareWindow;

            PoincareWindow.Mouse.ButtonDown += Mouse_ButtonDown;
            PoincareWindow.Mouse.ButtonUp += Mouse_ButtonUp;
        }
        public JoystickControl(JoystickDevice joystick, PoincareWindow poincareWindow)
        {
            Joystick = joystick;
            PoincareWindow = poincareWindow;

            Joystick.ButtonDown += Joystick_ButtonDown;
            Joystick.ButtonUp += Joystick_ButtonUp;
        }
        public KeyboardControl(PoincareWindow poincareWindow)
        {
            PoincareWindow = poincareWindow;

            PoincareWindow.Keyboard.KeyDown += Keyboard_KeyDown;
        }
        static void Main(string[] args)
        {
            ImageFiles = new List<string>();
            string defaultImageFileDir = System.IO.Path.Combine(System.Environment.CurrentDirectory, "Resources");
            ImageFiles.AddRange(GetImages(defaultImageFileDir));

            //		graphicsMode = new GraphicsMode(GraphicsMode.Default.ColorFormat, GraphicsMode.Default.Depth, GraphicsMode.Default.Stencil, graphicsModeSamples);
            graphicsMode = new GraphicsMode();

            foreach (string imageFileDir in args) {
                if (imageFileDir != string.Empty)
                    ImageFiles.AddRange(GetImages(imageFileDir));
            }

            // The 'using' idiom guarantees proper resource cleanup.
            // We request 30 UpdateFrame events per second, and unlimited
            // RenderFrame events (as fast as the computer can handle).
            using (PoincareWindow game = new PoincareWindow()) {
                game.Run(30.0);
            }
        }