Window

A Window

Constructors

this
this(string title, int width, int height)

Constructor

Destructor

~this
~this()

Destructor

Members

Functions

close
void close()

Set the close request flag

fullscreen
bool fullscreen()

Gets whether the window is fullscreen

fullscreen
void fullscreen(bool value)

Sets the window's fullscreen state

hide
void hide()

Hides the window

isExitRequested
bool isExitRequested()

Gets whether the window has requested to close (aka the game is requested to exit)

makeCurrent
void makeCurrent()

Makes the OpenGL context of the window current

resetViewport
void resetViewport()

Resets the OpenGL viewport to fit the window

resize
void resize(int width, int height)

Resizes the window

setSwapInterval
void setSwapInterval(SwapInterval interval)

Sets the swap interval, by default vsync

show
void show()

Show window

swapBuffers
void swapBuffers()

Swaps the OpenGL buffers for the window

update
void update()

poll for new window events

winPtr
GLFWwindow* winPtr()

Gets the glfw window pointer

Properties

height
int height [@property getter]

Gets the height of the window's framebuffer

title
string title [@property getter]

Gets the title of the window

title
string title [@property setter]

Sets the title of the window

width
int width [@property getter]

Gets the width of the window's framebuffer

Meta