💾 Archived View for thingvellir.net › log › 2024-01-01.gmi captured on 2024-12-17 at 10:17:53. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2024-05-12)
-=-=-=-=-=-=-
WIP
export fn AppletStart() -> void
Called by the host to initialize the module.
export fn AppletQuit() -> void
Called by the host to notify it's shutting down. (Currently not really that useful)
export fn AppletRender() -> void
Called by the host to tell the module to refresh its framebuffer.
export fn AppletEvent( kind: i32, arg_1: i32, arg_2: i32, arg_3: i32 ) -> i32
Called by the host in response to mouse or key events.
Key scancodes and modifiers are TBD.
export fn AppletDisplayWidth() -> i32
Returns the module's display width. The host should only call this once at startup.
export fn AppletDisplayHeight() -> i32
Returns the module's display height. The host should only call this once at startup.
export fn AppletDisplayPtr -> *u32
Returns a pointer to an array of width*height RGBA bytes. The host should only call this once at startup.
import fn Applet.Write(ptr: *u8, len: u32) -> void
A debugging aid. Writes UTF-8 text to an optional text buffer, without a newline.
import fn Applet.SetCursorLock(enable: i32) -> void
Requests the host to lock the cursor. Locked cursor movement gives mouse delta events instead of absolute position events.
Applets should account for the host not locking the cursor. Ideally, the host should try to lock the cursor when able.
import fn Applet.Quit(code: i32) -> noreturn
Requests the host to quit. The host should call AppletQuit, like in any other quit condition.