Class Platform

Namespace
Elegy.PlatformSystem.API
Assembly
Elegy.PlatformSystem.dll

Platforming system. Handles windowing and provides access to input.

public static class Platform
Inheritance
Platform
Inherited Members

Methods

AddWindow(IWindow)

Associates the window with the engine, and returns false if it's already associated.

public static bool AddWindow(IWindow window)

Parameters

window IWindow

Returns

bool

CreateWindow(in WindowOptions)

Creates a window, or returns null in case there's no window platform (dedicated server etc.)

public static IWindow? CreateWindow(in WindowOptions options)

Parameters

options WindowOptions

Returns

IWindow

GetCurrentInputContext()

Returns the currently focused window's input context, or null if there are no windows.

public static IInputContext GetCurrentInputContext()

Returns

IInputContext

GetCurrentWindow()

Returns the window that is currently in focus, or null if there are no windows.

public static IWindow? GetCurrentWindow()

Returns

IWindow

HasWindow(IWindow)

Returns whether the window is associated with the engine.

public static bool HasWindow(IWindow window)

Parameters

window IWindow

Returns

bool

Init(in LaunchConfig)

public static bool Init(in LaunchConfig config)

Parameters

config LaunchConfig

Returns

bool

RemoveWindow(IWindow)

Disassociates a window from the engine, and returns false if it's not found in the first place.

public static bool RemoveWindow(IWindow window)

Parameters

window IWindow

Returns

bool

Set(IWindowPlatform?)

public static void Set(IWindowPlatform? windowPlatform)

Parameters

windowPlatform IWindowPlatform

Shutdown()

public static void Shutdown()