Пример #1
0
        public OpenGLWindow
        (
            int width,
            int height,
            string title               = WindowDefaultSettings.WindowTitle,
            int updateFrequency        = WindowDefaultSettings.WindowUpdateFrequency,
            int renderFrequency        = WindowDefaultSettings.WindowRenderFrequency,
            FloatColor backgroundColor = null,
            Picture picture            = null
        )
            : base(width, height, GraphicsMode.Default, title)
        {
            Graphics.Initialize(this);
            TargetUpdateFrequency = updateFrequency;
            TargetRenderFrequency = renderFrequency;

            if (picture == null)
            {
                WindowPicture = Picture.Create();
            }
            else
            {
                WindowPicture = picture;
            }

            Graphics.SetBackground(backgroundColor);
        }
Пример #2
0
 public OpenGLWindow() : base
     (
         WindowDefaultSettings.WindowWidth,
         WindowDefaultSettings.WindowHeight,
         GraphicsMode.Default,
         WindowDefaultSettings.WindowTitle
     )
 {
     Graphics.Initialize(this);
     TargetUpdateFrequency = WindowDefaultSettings.WindowUpdateFrequency;
     TargetRenderFrequency = WindowDefaultSettings.WindowRenderFrequency;
     WindowPicture         = Picture.Create();
     Graphics.SetBackground(Color.White);
 }