not-fl3/macroquad
66.4
Adequate · 30 September 2026
16.3k
lines of production code
Rust
primary language
2
measurements over time
What this system is
This system is a Rust-based 2D and 3D game development library that provides core rendering, input handling, and audio capabilities across multiple platforms including web. It extends game logic support through experimental modules for coroutines, state machines, and an ECS-like scene architecture, alongside specialized crates for particle effects, platformer physics, and Tiled map integration. The library also includes a complete immediate-mode UI framework for building interactive interfaces and a profiler for visualizing performance telemetry.
How it got here
2020 — Initial release and core feature expansion
10 changes.
This period marks the initial release of the macroquad game library, establishing its core 2D rendering capabilities and foundational modules. It simultaneously expanded the ecosystem by introducing dedicated crates for audio, particle systems, Tiled map support, and platformer physics, while refining the build system with Rust 2021 migration and optional feature flags.
2021–2022 — Experimental features and immediate-mode UI
11 changes.
This period focused on introducing a suite of experimental modules, including coroutines, state machines, and camera controls, alongside a complete immediate-mode UI framework with a new rendering backend. Significant work also involved implementing a robust text editing engine, adding 2D geometry primitives, and establishing a JavaScript runtime for Web targets.
Features
Add 2D geometry primitives (Rect, Circle) and RectOffset
The math module now includes new \Rect\ and \Circle\ structs for 2D geometry, along with a \RectOffset\ helper. \Rect\ provides methods for creating, transforming, and querying rectangles, including edge accessors, center calculation, overlap detection, intersection, and a new \normalized\ method to ensure positive dimensions. \Circle\ offers construction, center/radius access, movement, scaling, and overlap checks against other circles and rectangles. Both types support const initialization where possible and derive standard traits like Clone, Copy, and Debug.
src/math · high confidence
Add mouse-controlled 2D camera with scroll/zoom support
A new \Camera\ struct is introduced in \src/experimental/camera/mouse.rs\ to enable 2D camera control via mouse input. Users can now adjust the camera's offset and scale interactively, including zooming in and out using the mouse wheel through the \scale\_wheel\ method. The camera state can be converted into a \Camera2D\ for rendering, allowing seamless integration with the existing graphics pipeline.
src/experimental/camera · high confidence
Immediate-mode UI widget library introduced
The \src/ui/widgets\ directory now contains a complete set of immediate-mode UI components, including Button, Checkbox, ComboBox, Drag, Editbox, Group, InputText, Label, Popup, ProgressBar, Separator, Slider, Tabbar, Texture, TreeNode, and Window. This adds a new capability for building interactive user interfaces with features such as draggable groups, tab navigation, and configurable widget sizing and positioning.
src/ui/widgets · high confidence
Initial audio support with optional feature flag
Added a new \audio\ module that provides functions to load and play sounds (\load\_sound\, \load\_sound\_from\_bytes\, \play\_sound\, \stop\_sound\, \set\_sound\_volume\). This functionality is gated behind the \audio\ Cargo feature; when disabled, a dummy implementation is used that prints a warning on Android and does nothing on other platforms, ensuring the library compiles and runs without audio dependencies unless explicitly enabled.
src · high confidence
Initial release of macroquad game library
This change introduces the macroquad crate, a simple and easy-to-use 2D game library for Rust inspired by raylib. It includes the core library code, comprehensive documentation in the README (covering setup, supported platforms like Windows/Linux/macOS/Android/iOS/Web, and build instructions), and dual licensing under Apache-2.0 and MIT.
(repo-wide) · high confidence
Initial release of the tiled crate for Tiled map support
This change introduces the \tiled\ crate, providing a new capability to load and render Tiled map files (TMX/JSON) within the macroquad ecosystem. The crate includes data structures for parsing map layers, tilesets, and objects, along with rendering functions that support tile flipping (horizontal, vertical, diagonal) and rotation. It also exposes flexible property value types (string, integer, float, boolean) and handles object layer GIDs, allowing users to integrate complex tile-based levels into their applications.
tiled · high confidence
Initial release of tiled-based platformer physics crate
The \physics-platformer\ crate introduces a new physics system for tile-based platformers, supporting static tiled layers with distinct tile types (Empty, Solid, JumpThrough, Collider) and dynamic actors/solids. It provides APIs to manage actor position and size, handles collision detection against both static tiles and moving solids, and implements specific platformer behaviors such as jump-through platforms and descent mechanics.
physics-platformer/src · high confidence
Introduce generational storage for coroutine state management
Added a new \GenerationalStorage\ component in \src/experimental/coroutines/generational\_storage.rs\ to manage coroutine data using generational IDs. This implementation prevents use-after-free errors and memory leaks by validating that a stored ID matches the current generation before allowing access or modification, ensuring that stale references do not corrupt or access overwritten data.
src/experimental/coroutines · high confidence
Introduction of immediate-mode UI framework
The \src/ui\ module now provides a complete immediate-mode graphical user interface library. This includes a layout system with a GUI cursor for automatic widget positioning, a drawing canvas for custom primitives like lines and textures, and a style builder for configuring fonts, colors, and hover/click states. The framework exposes a suite of standard widgets such as buttons, checkboxes, comboboxes, edit boxes, sliders, progress bars, tab bars, and windows, along with input handling for mouse and keyboard events.
src/ui · high confidence
Introduction of the particle system module
A new particle system library has been added to the project, providing configurable particle emitters with support for various emission shapes (point, rectangle, sphere), customizable particle properties (lifetime, velocity, direction, spread), and shader-based rendering. The module includes a GLSL shader for particle transformation and UV mapping, along with Rust structs for configuration and serialization, enabling users to create dynamic visual effects within the macroquad framework.
particles · high confidence
New bundled JavaScript runtime and audio support for Web targets
The \js\ directory now includes \mq\_js\_bundle.js\, a single-file JavaScript bundle that provides the Web runtime environment for the engine. This bundle integrates WebGL context management, input event handling (mouse, keyboard, touch, clipboard, file drag-and-drop), and a native JavaScript audio implementation using the Web Audio API. It also includes utilities for JavaScript object interop (\sapp\_jsutils\) and networking (\quad-net\). A \README.md\ has been added to document the bundle's contents and the build script used to generate it.
js · high confidence
New examples for 3D, camera, and custom materials
The examples directory now includes demonstrations for 3D rendering (3d.rs), 2D camera transformations (camera.rs, camera\_transformations.rs), and custom shader materials (custom\_material.rs). These additions allow users to explore 3D primitives, camera zoom/rotation/offset, and loading custom GLSL/Metal shaders with uniform arrays.
examples · high confidence
New experimental modules for animation, coroutines, scenes, and state machines
This release introduces a suite of experimental APIs in \src/experimental\ to support more complex game logic. The new \animation\ module provides an \AnimatedSprite\ for managing tile-based sprite animations with configurable frames and FPS. The \coroutines\ module enables asynchronous multitasking via \start\_coroutine\, supporting manual polling for pause states and value retrieval. A new \scene\ module implements an Entity-Component-System (ECS)-like architecture with \Handle\, \RefMut\, and a capabilities system for node interactions, backed by an arena allocator for performance. Finally, the \state\_machine\ module allows defining state machines with update, coroutine, and on-end hooks, integrating with the scene and coroutine systems for state transitions.
src/experimental · high confidence
New profiler module for visualizing macroquad telemetry
A new profiler crate has been added to visualize macroquad's telemetry data. It provides a UI window that displays a frames history graph, allowing users to inspect frame times and select specific frames to view detailed zone breakdowns and GPU query metrics.
profiler · high confidence
Behavioural changes
New font atlas implementation with dynamic resizing and memory management
The text rendering subsystem now uses a new \Atlas\ struct to manage font textures. This change introduces automatic atlas resizing when glyph capacity is exceeded, ensuring that large fonts or many glyphs do not fail to render. It also includes proper memory cleanup via the \Drop\ implementation to delete old textures, preventing memory leaks. Additionally, users can now configure the texture filtering mode for fonts and atlases, allowing control over how text appears when scaled.
src/text · high confidence
New immediate-mode UI rendering backend
The UI rendering pipeline has been replaced with a new immediate-mode system located in \src/ui/render\. This change introduces a two-stage process: a \Painter\ component that translates high-level UI primitives (such as labels, rectangles, sprites, and lines) into a sequence of \DrawCommand\ objects, and a \MeshRasterizer\ that converts these commands into GPU-drawable vertex and index buffers. This new architecture supports advanced styling features like nine-slice scaling for sprites, explicit clipping zones, and texture-based button content, while fixing previous issues with text measurement, label alignment on high-DPI displays, and clipping offsets.
src/ui/render · high confidence
New text editing engine for the Editbox widget
The Editbox widget now uses a new internal text editor implementation located in src/ui/widgets/editbox/text\_editor.rs. This change introduces a command-based architecture that supports undo/redo operations for character and string insertions and deletions. It also adds robust selection handling, allowing users to select individual characters, words, or lines, and includes logic to manage cursor positioning and click states (such as double-click detection) for a more responsive text editing experience.
src/ui/widgets/editbox · high confidence
Support for Result-returning main functions and crate renaming
The \\#\[macroquad::main\]\ proc-macro now allows the user-defined main function to return a \Result\ type; if a \Result\ is returned, the generated wrapper will catch errors and log them using the crate's logging system instead of panicking. Additionally, the macro now supports a \crate\_rename\ configuration option, allowing users to specify a different name for the \macroquad\ crate in their \Cargo.toml\ (e.g., via \\[dependencies.macroquad\]\ with a \package\ or \rename\ key) so that the generated code references the correct crate name.
_macroquad\macro/src · high confidence
Test coverage
Added tests for coroutine behavior and memory management
Added four new integration tests in the \tests\ directory to verify coroutine functionality. \back\_to\_the\_future.rs\ tests basic Future implementation safety. \back\_to\_the\_future\_coroutines.rs\ validates that coroutines can run concurrently with the main thread without blocking it. \coroutine\_pause.rs\ ensures that manual polling and pausing mechanisms work correctly, allowing precise control over coroutine execution timing. \coroutine\_values.rs\ confirms that coroutines can return values and that active coroutine counts are correctly tracked for memory leak detection.
tests · high confidence
Dependencies
Macroquad 0.4.16: Rust 2021 edition, dependency upgrades, and new optional features
The macroquad crate has been updated to version 0.4.16, migrating the project to the Rust 2021 edition. This release upgrades core dependencies, including miniquad to 0.4.11, glam to 0.27, and image to 0.24, while introducing new optional Cargo features for audio support (quad-snd), logging (log-rs), and glam serialization (glam-serde). Additionally, the main crate now depends on the newly extracted macroquad\_macro proc-macro crate.
(dependencies) · high confidence
Housekeeping
Add internal documentation and licensing files to macroquad\_macro
The macroquad\_macro crate now includes a README.md identifying it as an internal crate for macroquad, along with LICENSE-APACHE and LICENSE-MIT files to clarify the software licensing terms for users and contributors.
_macroquad\macro · high confidence
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Score
- CAI 63 → 66 (+3.1)
- Rubric changed (rubric-2026.09.11 → rubric-2026.09.18) — scores are not directly comparable.
Lenses
- Code Health 89 → 89 (+0.0)
- Architecture 100 → 97 (-3.0)
- Maturity 61 → 61 (+0.0)
- Readiness 47 → 54 (+7.0)
- Security 89 → 89 (+0.0)
- Event Sourcing 100 → 100 (+0.0)
- Performance 100 (new)
Resolved (4)
- Documentation: no architecture or design documentation (README.md)
- Documentation: no installation or build instructions (README.md)
- Documentation: no usage examples (README.md)
- Off-boarding risk: anonymized user #1
New (8)
- Dependency hygiene PARTLY measured — Cargo dependencies read, no committed lock to grade for currency
- Documentation: no contributor guidance (README.md)
- Inconsistent return types for dimension queries. Image returns usize (integer counts), while Texture2D returns f32 (floating point coordinates/pixels). This forces users to cast or handle type mismatches when working with both types generically. Additionally, Texture2D provides size() returning Vec2, while Image does not.
- Low cohesion: Stage (LCOM4 15) (src/lib.rs)
- Low cohesion: Style (LCOM4 4) (src/ui/style.rs)
- Off-boarding risk: anonymized user #1
- Projects may be oversized for their cohesion
- Semantic ambiguity of 'point'. In Circle, this likely returns the center or a sample point, but the name is generic. In Rect, it is unclear if it returns the top-left corner, center, or something else. Given that Rect has explicit center(), left(), right(), etc., point() on Rect is redundant or confusingly named compared to the explicit getters available on the same type.
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
not-fl3/macroquad was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 30 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit 8d602d3f8ebb8a3a582ee15d92983bbb81ee3ef6 — the exact code this score is about.
- Scored under rubric-2026.09.18 — the same rubric and the same method as every other entry in this index.
- Measured by watchdog.canine.dev using codehealth-analyzer preprod-cb25ca4feafa.