Every library in the loft registry. Each one is written in loft itself, so its source reads like your own code. Install one with loft install <name>, then use <name>; in your program.
| Library | Version | What it gives you |
assets | 0.5.3 | A game's content pack that IS a loft store — art, audio and the scenes that place them, range-read off a static file server. No codec, no parse step, no server-side code. |
audio | 0.2.8 | Clips, voices and one mix: the same sound on a PC and on a 32-bit device |
audio_bus | 0.2.1 | A mixer for game audio — buses that multiply, and a duck that restores exactly |
fixstep | 0.1.4 | A fixed simulation step in exact integer time — clock, bank, one-shot timer |
game_protocol | 0.1.9 | The message types a multiplayer game's client and server share — envelopes, kinds and constructors; pure loft, transport-agnostic |
gpu | 0.4.3 | Drawing on a GPU through pipelines, passes and uniform blocks, with no graphics stack named: a backend library beneath it draws |
gpu_gl | 0.3.6 | The OpenGL backend of gpu: OpenGL 3.3 on Linux and macOS, OpenGL ES 3 on Android, WebGL2 in a page |
gpu_host | 0.1.1 | Opens a gpu device on the backend this machine has: Metal on a Mac, OpenGL elsewhere and where Metal is absent, Vulkan on Linux by name |
gpu_metal | 0.2.3 | The Metal backend of gpu: a Mac's GPU through Metal, in a window of its own |
gpu_paint | 0.2.1 | Rectangles, images and sprites at pixel positions, drawn through gpu: a painter and sprite sheets for any backend |
gpu_vulkan | 0.2.4 | The Vulkan backend of gpu: Vulkan 1.3 on Linux, in an X11 window |
input | 0.3.3 | Game input for loft — action/axis bindings resolved to per-tick input state. |
scene3d | 0.7.0 | A 3D scene a game's view gives once — tiles of faces, the cells' light, actors — drawn through gpu |
screen | 0.2.2 | A small frame on the machine's screen, scaled up, with the keys of its window — one API on a desktop and a device |
stage | 0.21.3 | A retained 2-D scene for loft: a node tree you mutate, with transforms, clipping, batching, pointer routing and widget states |
tile_world | 0.14.3 | An unbounded, layered square-grid world, and the routines that answer questions about it: paths, sight and light |
tiles | 0.7.2 | Tile sheets, map layers and sprites drawn at a surface's own resolution through a camera |
time | 0.4.3 | Date/time arithmetic on millisecond-since-epoch integers — proleptic Gregorian, same model as JavaScript Date. Pure-loft; identical results on interp, --native, WASM. |
tween | 0.1.3 | Property tweens in exact integer time — eleven easing curves, chains and groups |
| Library | Version | What it gives you |
hex_body | 0.3.8 | The moving body — rigs, revolute joints with computed limits, pure poses, and collision proxies. hexbody's own body model, part of the hex_* family. |
hex_draw | 0.1.12 | Draw a model into the field, and read its wall surface back. |
hex_edge | 0.2.12 | Collision as an edge set, and the analytic surfaces behind it. |
hex_field | 0.1.13 | Exact-integer hex cell sets and their outlines — the base of the hex_* family. |
hex_fit | 0.1.7 | The doorstep — refuse at authoring time what would not round-trip. |
hex_form | 0.1.10 | The exact turtle form on the hex lattice, and its canonical text. |
hex_grid | 0.1.5 | Hex-grid geometry — pointy-top, ODD-R OFFSET coordinates: coordinate/pixel conversion, neighbours, distance, corners and canonical edges, plus a square local basis for right-angled structures placed on the hex world. |
hex_ground | 0.1.6 | The ground of one place: a height and a surface kind per cell, shaped into terraces, a hill, a seat, a cut and cliffs |
hex_place | 0.1.8 | Place, seat and combine — the operations a model survives. |
hex_recover | 0.1.8 | Rebuild a model from the field — exactly, or with a reported residual. |
hex_roof | 0.1.12 | Roof profiles as a height field, and the fit that recovers them. |
hex_shape | 0.1.12 | The line primitive, the box and the arc — the shape vocabulary of the hex_* family. |
hex_walk | 0.1.2 | A body walking through a built world: walls, steps, doorways it eases into, door leaves it pushes and pulls, ladders, and a head that turns before the body. |
hex_way | 0.1.8 | A way is an exact centreline plus offsets, never a rasterised band. |
mesh3d | 0.1.6 | 3D geometry primitives — Vec/Mat, Mesh, Scene, Camera, Light. Standalone (pure-loft, no GPU). |
shapes | 0.5.6 | 2D geometry primitives — Rect, Circle, overlap tests, clamp. Pure-loft, no other deps. |
| Library | Version | What it gives you |
drawing | 0.5.4 | Render a .draw scene — a sprite authored as lines of text — pixel-identically to the Python renderer it replaces |
glb | 0.1.10 | glTF 2.0 binary (.glb) reader and writer — exports Mesh / Scene as a glb file readable by Blender, three.js, gltf-validator, and reads a glb back into them. Standalone (pure-loft, no GPU). |
gpu | 0.4.3 | Drawing on a GPU through pipelines, passes and uniform blocks, with no graphics stack named: a backend library beneath it draws |
gpu_gl | 0.3.6 | The OpenGL backend of gpu: OpenGL 3.3 on Linux and macOS, OpenGL ES 3 on Android, WebGL2 in a page |
gpu_host | 0.1.1 | Opens a gpu device on the backend this machine has: Metal on a Mac, OpenGL elsewhere and where Metal is absent, Vulkan on Linux by name |
gpu_metal | 0.2.3 | The Metal backend of gpu: a Mac's GPU through Metal, in a window of its own |
gpu_paint | 0.2.1 | Rectangles, images and sprites at pixel positions, drawn through gpu: a painter and sprite sheets for any backend |
gpu_record | 0.3.1 | A GPU backend that draws nothing and writes down every call it receives: for testing a program's drawing on a machine with no display |
gpu_vulkan | 0.2.4 | The Vulkan backend of gpu: Vulkan 1.3 on Linux, in an X11 window |
graphics | 0.14.6 | A 2D canvas, windows, drawing on the GPU and text for loft (meshes and glTF are mesh3d and glb) |
gridmesh | 0.2.10 | Chunk-local mesh-generation primitives for world-building algorithms. |
imaging | 0.5.7 | PNG load/save and pixel manipulation for loft: one C source on every target, no Rust crate |
lavition_ui | — | Panel layout, hit-testing and text metrics for an in-engine editor UI: rectangles and hits, with no world, no lattice, no window and no GL. |
mesh3d | 0.1.6 | 3D geometry primitives — Vec/Mat, Mesh, Scene, Camera, Light. Standalone (pure-loft, no GPU). |
scene3d | 0.7.0 | A 3D scene a game's view gives once — tiles of faces, the cells' light, actors — drawn through gpu |
screen | 0.2.2 | A small frame on the machine's screen, scaled up, with the keys of its window — one API on a desktop and a device |
stage | 0.21.3 | A retained 2-D scene for loft: a node tree you mutate, with transforms, clipping, batching, pointer routing and widget states |
text2d | 0.4.9 | Text that always draws — a built-in face, a glyph atlas, measured metrics, wrapping and alignment, with no font file and no GL context |
tiles | 0.7.2 | Tile sheets, map layers and sprites drawn at a surface's own resolution through a camera |
| Library | Version | What it gives you |
html | 0.1.4 | HTML escaping helpers for loft. |
markdown | 0.2.6 | Markdown-to-HTML rendering for loft — headings, inline spans, slugify, link rewriting. |
regex | 0.6.4 | Small-script regex: `search`, `matches`, `capture` / `capture_all` with groups, `replace_on` and a lazy `split_on`, with a cache of compiled patterns. |
text2d | 0.4.9 | Text that always draws — a built-in face, a glyph atlas, measured metrics, wrapping and alignment, with no font file and no GL context |
zttext | 0.1.7 | A text engine for loft: piece-table content core, transactional undo, and portable layout with measurement injected |