{"schemaVersion":"1.0","record":{"label":"Macroquad","description":"Cross-platform Rust game library with immediate drawing APIs, frame-oriented async control flow and optional audio.","aliases":[],"kind":"software","website":"https://macroquad.rs/","overview":"Macroquad is a Rust game library inspired by raylib, with immediate drawing functions and a frame-oriented application loop. It provides 2D graphics, interface tools and additional modules for cameras and 3D primitives. Desktop, browser and mobile targets are documented, although platform packaging and selected Cargo features remain part of the application's setup.","license":"MIT OR Apache-2.0; dependencies and imported content retain their own terms.","lifecycle":"active","example":false,"features":[{"name":"Frame-oriented Rust loop","status":"supported","detail":"An async main function yields through next_frame; the project uses this to coordinate cross-platform frame execution.","useCase":"Programming small cross-platform games and interactive graphics in Rust","platforms":["Windows","Linux","macOS","Web","Android","iOS"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://github.com/not-fl3/macroquad","locator":"raylib inspiration, platform builds, Linux dependencies and async/await design","retrievedAt":"2026-10-07T20:40:10Z","kind":"vendor"}]},{"name":"Audio","status":"limited","detail":"Audio APIs are provided, but the inspected manifest makes quad-snd optional through the audio feature; defaults are empty.","useCase":"Programming small cross-platform games and interactive graphics in Rust","platforms":["Windows","Linux","macOS","Web","Android","iOS"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://docs.rs/macroquad/latest/macroquad/audio/index.html","locator":"Load/play/stop and volume APIs","retrievedAt":"2026-10-07T20:40:44Z","kind":"vendor"},{"url":"https://github.com/not-fl3/macroquad/blob/master/Cargo.toml","locator":"MIT OR Apache-2.0, empty default features and audio/quad-snd dependency","retrievedAt":"2026-10-07T20:40:44Z","kind":"vendor"}]},{"name":"Cross-platform asset access","status":"limited","detail":"Desktop loads use filesystem paths while web loads use HTTP; desktop asset-root configuration can align packaged paths.","useCase":"Programming small cross-platform games and interactive graphics in Rust","platforms":["Windows","Linux","macOS","Web","Android","iOS"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://docs.rs/macroquad/latest/macroquad/file/fn.load_file.html","locator":"Async function; PC filesystem versus web HTTP","retrievedAt":"2026-10-07T20:40:55Z","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/file/fn.set_pc_assets_folder.html","locator":"Desktop current-directory paths versus packaged Android asset root","retrievedAt":"2026-10-07T20:40:55Z","kind":"vendor"}]},{"name":"Custom materials","status":"supported","detail":"Materials support shaders and uniforms, with load-time parameter configuration.","useCase":"Programming small cross-platform games and interactive graphics in Rust","platforms":["Windows","Linux","macOS","Web","Android","iOS"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://docs.rs/macroquad/latest/macroquad/material/index.html","locator":"Material load-time parameters and subsequent rendering selection","retrievedAt":"2026-10-07T20:40:55Z","kind":"vendor"}]},{"name":"Mobile delivery","status":"limited","detail":"Android and iOS are documented targets; the iOS guide distinguishes bundles/resources from signing and provisioning for a device.","useCase":"Programming small cross-platform games and interactive graphics in Rust","platforms":["Windows","Linux","macOS","Web","Android","iOS"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://github.com/not-fl3/macroquad","locator":"raylib inspiration, platform builds, Linux dependencies and async/await design","retrievedAt":"2026-10-07T20:40:10Z","kind":"vendor"},{"url":"https://macroquad.rs/articles/ios/","locator":"Application bundle, resources and real-device signing/provisioning distinction","retrievedAt":"2026-10-07T20:40:35Z","kind":"vendor"}]}],"alternatives":[],"slug":"macroquad","draftAlternatives":[{"targetSlug":"raylib","status":"limited","detail":"Assessment: a Rust-oriented alternative for small code-driven graphics and game projects inspired by raylib's approach. APIs and frame organization differ, and audio features, asset paths and platform packaging must be adapted rather than assumed compatible.","useCase":"Programming small cross-platform games and interactive graphics in Rust","platforms":["Windows","Linux","macOS","Web","Android","iOS"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://github.com/not-fl3/macroquad","locator":"raylib inspiration, platform builds, Linux dependencies and async/await design","retrievedAt":"2026-10-07T20:40:10Z","kind":"vendor"},{"url":"https://www.raylib.com/","locator":"Code-driven C game library and graphics/audio modules","retrievedAt":"2026-10-07T20:40:44Z","kind":"vendor"},{"url":"https://github.com/not-fl3/macroquad/blob/master/Cargo.toml","locator":"MIT OR Apache-2.0, empty default features and audio/quad-snd dependency","retrievedAt":"2026-10-07T20:40:44Z","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/file/fn.set_pc_assets_folder.html","locator":"Desktop current-directory paths versus packaged Android asset root","retrievedAt":"2026-10-07T20:40:55Z","kind":"vendor"}]}],"evidence":[{"url":"https://github.com/not-fl3/macroquad","locator":"raylib inspiration, platform builds, Linux dependencies and async/await design","retrievedAt":"2026-10-07T20:40:10Z","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/","locator":"Modules, immediate UI, cameras and experimental namespace warning","retrievedAt":"2026-10-07T20:40:35Z","kind":"vendor"},{"url":"https://github.com/not-fl3/macroquad/blob/master/Cargo.toml","locator":"MIT OR Apache-2.0, empty default features and audio/quad-snd dependency","retrievedAt":"2026-10-07T20:40:44Z","kind":"vendor"},{"url":"https://github.com/not-fl3/macroquad/blob/master/LICENSE-MIT","locator":"Commercial/modification permissions and notice retention","retrievedAt":"2026-10-07T20:40:44Z","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/file/fn.load_file.html","locator":"Async function; PC filesystem versus web HTTP","retrievedAt":"2026-10-07T20:40:55Z","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/file/fn.set_pc_assets_folder.html","locator":"Desktop current-directory paths versus packaged Android asset root","retrievedAt":"2026-10-07T20:40:55Z","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/material/index.html","locator":"Material load-time parameters and subsequent rendering selection","retrievedAt":"2026-10-07T20:40:55Z","kind":"vendor"},{"url":"https://macroquad.rs/articles/ios/","locator":"Application bundle, resources and real-device signing/provisioning distinction","retrievedAt":"2026-10-07T20:40:35Z","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/audio/index.html","locator":"Load/play/stop and volume APIs","retrievedAt":"2026-10-07T20:40:44Z","kind":"vendor"},{"url":"https://www.raylib.com/","locator":"Code-driven C game library and graphics/audio modules","retrievedAt":"2026-10-07T20:40:44Z","kind":"vendor"}],"document":{"version":1,"references":[{"url":"https://github.com/not-fl3/macroquad","locator":"raylib inspiration, platform builds, Linux dependencies and async/await design","retrievedAt":"2026-10-07T20:40:10Z","id":"repo","title":"Macroquad repository","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/","locator":"Modules, immediate UI, cameras and experimental namespace warning","retrievedAt":"2026-10-07T20:40:35Z","id":"api","title":"Macroquad 0.4.16 API","kind":"vendor"},{"url":"https://github.com/not-fl3/macroquad/blob/master/Cargo.toml","locator":"MIT OR Apache-2.0, empty default features and audio/quad-snd dependency","retrievedAt":"2026-10-07T20:40:44Z","id":"manifest","title":"Macroquad manifest","kind":"vendor"},{"url":"https://github.com/not-fl3/macroquad/blob/master/LICENSE-MIT","locator":"Commercial/modification permissions and notice retention","retrievedAt":"2026-10-07T20:40:44Z","id":"license","title":"Macroquad MIT option","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/file/fn.load_file.html","locator":"Async function; PC filesystem versus web HTTP","retrievedAt":"2026-10-07T20:40:55Z","id":"files","title":"Macroquad file loading","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/file/fn.set_pc_assets_folder.html","locator":"Desktop current-directory paths versus packaged Android asset root","retrievedAt":"2026-10-07T20:40:55Z","id":"paths","title":"Macroquad desktop asset roots","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/material/index.html","locator":"Material load-time parameters and subsequent rendering selection","retrievedAt":"2026-10-07T20:40:55Z","id":"material","title":"Macroquad material API","kind":"vendor"},{"url":"https://macroquad.rs/articles/ios/","locator":"Application bundle, resources and real-device signing/provisioning distinction","retrievedAt":"2026-10-07T20:40:35Z","id":"ios","title":"Macroquad iOS guide","kind":"vendor"},{"url":"https://docs.rs/macroquad/latest/macroquad/audio/index.html","locator":"Load/play/stop and volume APIs","retrievedAt":"2026-10-07T20:40:44Z","id":"audio","title":"Macroquad audio API","kind":"vendor"},{"url":"https://www.raylib.com/","locator":"Code-driven C game library and graphics/audio modules","retrievedAt":"2026-10-07T20:40:44Z","id":"raylib","title":"raylib overview","kind":"vendor"}],"overviewCitations":["repo","api"],"licenseCitations":["manifest","license"],"sections":[{"id":"loop","heading":"Programming model","paragraphs":[{"id":"loop-detail","content":[{"text":"Macroquad's examples use ordinary drawing calls inside an async main loop and yield with next_frame. The repository explains this as a way to preserve application state between frames across platforms, especially the browser. It does not rely on a separate general-purpose async runtime for that loop. The model should therefore be understood as frame coordination, not an assurance that arbitrary executor-dependent asynchronous libraries integrate automatically."}],"citations":["repo"]}]},{"id":"graphics","heading":"Graphics and interface scope","paragraphs":[{"id":"graphics-detail","content":[{"text":"The API exposes 2D shapes, textures, text, immediate-mode UI, 2D/3D cameras and 3D primitive facilities. Custom materials select shaders and uniforms for subsequent drawing calls. Their load-time MaterialParams configuration is distinct from per-frame drawing state. Experimental modules are explicitly marked unstable and may move or disappear, so they should not be treated as equally stable parts of the library's interface."}],"citations":["api","material"]}]},{"id":"assets","heading":"Files and asset roots","paragraphs":[{"id":"assets-detail","content":[{"text":"File loading uses the local filesystem on desktop and HTTP requests on the web. Asset-root conventions can differ even when application code is shared: a desktop project commonly references an assets directory, while Android packaging can make that directory the resource root. The set_pc_assets_folder helper aligns desktop lookups with that arrangement. Exported applications still need their files deployed at the paths the loader expects."}],"citations":["files","paths"]}]},{"id":"audio","heading":"Audio and dependency selection","paragraphs":[{"id":"audio-detail","content":[{"text":"Macroquad documents sound loading from files or bytes, playback, stopping and volume control. In the inspected 0.4.16 manifest, however, the audio backend is an optional dependency enabled by the audio feature and the default feature list is empty. The presence of an audio module in documentation built with all features is not enough to establish that an application's dependency declaration enables sound."}],"citations":["audio","manifest"]}]},{"id":"delivery","heading":"Platform builds","paragraphs":[{"id":"delivery-detail","content":[{"text":"The repository documents Windows, Linux, macOS, web, Android and iOS targets, with platform-specific build steps. Browser output includes a WebAssembly file and JavaScript/HTML loading setup. The iOS guide distinguishes simulator bundles from real-device signing and provisioning. Linux build dependencies are listed in the README, so broad minimal-dependency marketing should not be interpreted as eliminating every platform toolchain or system-library requirement."}],"citations":["repo","ios"]}]},{"id":"license","heading":"License and substitution","paragraphs":[{"id":"license-detail","content":[{"text":"Macroquad offers an MIT or Apache-2.0 license choice. It is a relevant alternative to "},{"text":"raylib","targetSlug":"raylib"},{"text":" for developers who want a similarly code-driven approach implemented in Rust. The comparison concerns small games and interactive graphics, not compatible source files or identical rendering behavior. Existing projects need their main loop, asset loading, optional audio and target packaging adapted to Macroquad's conventions."}],"citations":["manifest","license","repo","raylib","paths"]}]}]},"id":"Q1011","revision":1059,"updatedAt":"2026-10-13T19:08:59Z","sourceUrl":"https://substitutefor.net/entities/Q1011?revision=1059"}}