Skip to content

MTY_AppCreate

chrisd1100 edited this page Apr 9, 2023 · 2 revisions

Create an MTY_App that handles input and window creation.

MTY_App *MTY_AppCreate(
    MTY_AppFlag   flags,
    MTY_AppFunc   appFunc,
    MTY_EventFunc eventFunc,
    void *        opaque
);

Parameters

flags (MTY_AppFlag)

appFunc (MTY_AppFunc)

Function called once per message cycle.

eventFunc (MTY_EventFunc)

Function called once per event fired.

opaque (void *)

Your application's top level context, passed to a variety of callbacks in the App module.

Return value

MTY_App *

On failure, NULL is returned. Call MTY_GetLog for details.

The returned MTY_App must be destroyed with MTY_AppDestroy.

Platform support

Windows   macOS   Android   Linux   Web  

See also

Module: App

Clone this wiki locally