MiniQuake2

src/miniquake2/platform/window.ml

Provides miniquake2 platform window facilities for this project.

Package
miniquake2.platform.window
Reachable
Yes

Imports

Declarations

applyNativeWindowMode

function applyNativeWindowMode(width, height, fullscreen)

Apply one native mode transaction and return the verified client size. The caller retains the logical Window fields until this transaction succeeds.

ParameterTypeDefaultDescription
widthdynamic—Width in the coordinate or storage units used by the caller.
heightdynamic—Height in the coordinate or storage units used by the caller.
fullscreendynamic—fullscreen value consumed by this operation.

View source

create

function create(title, width, height, fullscreen)

Creates create for the miniquake2 platform window module.

ParameterTypeDefaultDescription
titledynamic—Human-readable title presented to the user.
widthdynamic—Width in the coordinate or storage units used by the caller.
heightdynamic—Height in the coordinate or storage units used by the caller.
fullscreendynamic—fullscreen value consumed by this operation.

View source

destroy

function destroy(window)

Return the destroy value.

ParameterTypeDefaultDescription
windowdynamic—window value consumed by this operation.

View source

miniquake2.platform.window.InputEvent struct

poll

function poll(window)

Performs the poll operation for the miniquake2 platform window module.

ParameterTypeDefaultDescription
windowdynamic—window value consumed by this operation.

View source

popInputEvent

function popInputEvent()

Return the pop input event value.

View source

reconfigure

function reconfigure(window, width, height, fullscreen)

Reconfigure one live Win32 window without destroying its OpenGL context. Changing display mode and frame style in place preserves every registered GPU resource and, consequently, the active level and client presentation.

ParameterTypeDefaultDescription
windowdynamic—window value consumed by this operation.
widthdynamic—Width in the coordinate or storage units used by the caller.
heightdynamic—Height in the coordinate or storage units used by the caller.
fullscreendynamic—fullscreen value consumed by this operation.

View source

resolvedDisplayMode

function resolvedDisplayMode(width, height, fullscreen, exclusiveAvailable, desktopWidth, desktopHeight)

Resolve a fixed Quake II menu mode to a mode the active monitor can safely display. The third value selects the native "use current display mode" borderless fallback.

ParameterTypeDefaultDescription
widthdynamic—Width in the coordinate or storage units used by the caller.
heightdynamic—Height in the coordinate or storage units used by the caller.
fullscreendynamic—fullscreen value consumed by this operation.
exclusiveAvailabledynamic—exclusiveAvailable value consumed by this operation.
desktopWidthdynamic—desktopWidth value consumed by this operation.
desktopHeightdynamic—desktopHeight value consumed by this operation.

View source

setMouseCapture

function setMouseCapture(enabled)

Set mouse capture.

ParameterTypeDefaultDescription
enableddynamic—enabled value consumed by this operation.

View source

setTitle

function setTitle(window, title)

Set title.

ParameterTypeDefaultDescription
windowdynamic—window value consumed by this operation.
titledynamic—Human-readable title presented to the user.

View source

setVerticalSync

function setVerticalSync(window, enabled)

Apply the archived Quake II swap interval to the live OpenGL context.

ParameterTypeDefaultDescription
windowdynamic—window value consumed by this operation.
enableddynamic—enabled value consumed by this operation.

View source

swap

function swap(window)

Swap state.

ParameterTypeDefaultDescription
windowdynamic—window value consumed by this operation.

View source

miniquake2.platform.window.Window struct