OpenTK.GLControl OpenGL-aware WinForms control. The WinForms designer will always call the default constructor. Inherit from this class and call one of its specialized constructors to enable antialiasing or custom s. Required designer variable. Clean up any resources being used. true if managed resources should be disposed; otherwise, false. Required method for Designer support - do not modify the contents of this method with the code editor. Constructs a new instance. Constructs a new instance with the specified GraphicsMode. The OpenTK.Graphics.GraphicsMode of the control. Constructs a new instance with the specified GraphicsMode. The OpenTK.Graphics.GraphicsMode of the control. The major version for the OpenGL GraphicsContext. The minor version for the OpenGL GraphicsContext. The GraphicsContextFlags for the OpenGL GraphicsContext. Raises the HandleCreated event. Not used. Raises the HandleDestroyed event. Not used. Raises the System.Windows.Forms.Control.Paint event. A System.Windows.Forms.PaintEventArgs that contains the event data. Raises the Resize event. Note: this method may be called before the OpenGL context is ready. Check that IsHandleCreated is true before using any OpenGL methods. A System.EventArgs that contains the event data. Execute the delayed context update Raises the ParentChanged event. A System.EventArgs that contains the event data. Swaps the front and back buffers, presenting the rendered scene to the screen. This method will have no effect on a single-buffered GraphicsMode. Makes current in the calling thread. All OpenGL commands issued are hereafter interpreted by this context. When using multiple GLControls, calling MakeCurrent on one control will make all other controls non-current in the calling thread. A GLControl can only be current in one thread at a time. To make a control non-current, call GLControl.Context.MakeCurrent(null). Grabs a screenshot of the frontbuffer contents. When using multiple GLControls, ensure that is current before accessing this property. A System.Drawing.Bitmap, containing the contents of the frontbuffer. Occurs when no OpenTK.Graphics.GraphicsContext is current in the calling thread. Gets the CreateParams instance for this GLControl Gets a value indicating whether the current thread contains pending system messages. Gets the IGraphicsContext instance that is associated with the GLControl. The associated IGraphicsContext is updated whenever the GLControl handle is created or recreated. When using multiple GLControls, ensure that Context is current before performing any OpenGL operations. Gets the aspect ratio of this GLControl. Gets or sets a value indicating whether vsync is active for this GLControl. When using multiple GLControls, ensure that is current before accessing this property. Gets the GraphicsMode of the IGraphicsContext associated with this GLControl. If you wish to change GraphicsMode, you must destroy and recreate the GLControl. Gets the for this instance. Needed to delay the invoke on OS X. Also needed because OpenTK is .NET 2, otherwise I'd use an inline Action. Use this overload only with IntPtr.Zero for the first argument. AGL context implementation for WinForms compatibility.