Show / Hide Table of Contents

Class GLFWGraphicsContext

OpenGL context implemented using GLFW.

Inheritance
object
GLFWGraphicsContext
Implements
IGLFWGraphicsContext
IGraphicsContext
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: OpenTK.Windowing.Desktop
Assembly: OpenTK.Windowing.Desktop.dll
Syntax
public class GLFWGraphicsContext : IGLFWGraphicsContext, IGraphicsContext

Constructors

GLFWGraphicsContext(Window*)

Initializes a new instance of the GLFWGraphicsContext class, a GLFW managed opengl context.

Declaration
public GLFWGraphicsContext(Window* windowPtr)
Parameters
Type Name Description
Window* windowPtr

The window pointer that is associated with the context.

Properties

IsCurrent

Gets a value indicating whether the context is the current active on of the current thread.

Declaration
public bool IsCurrent { get; }
Property Value
Type Description
bool

SwapInterval

Gets or sets the swap interval (the number of screen updates to wait between swapping front and back buffers. See SwapBuffers()).

Declaration
public int SwapInterval { get; set; }
Property Value
Type Description
int

The swap interval.

WindowPtr

The GLFW Window that represents the context.

Declaration
public IntPtr WindowPtr { get; }
Property Value
Type Description
IntPtr

Methods

MakeCurrent()

Makes the GraphicsContext current on the calling thread.

Declaration
public void MakeCurrent()

MakeNoneCurrent()

Makes no GraphicsContext current one on the calling thread.

Declaration
public void MakeNoneCurrent()

SwapBuffers()

Swaps the front and back buffers of the current GraphicsContext, presenting the rendered scene to the user.

Declaration
public void SwapBuffers()

Implements

IGLFWGraphicsContext
IGraphicsContext
In This Article
Back to top Generated by DocFX