Thank you for your interest in contributing to Proof Engine! This document provides guidelines and instructions for contributing.
- Fork the repository on GitLab (https://gitlab.com/mattbusel/proof-engine)
- Clone your fork locally:
git clone https://gitlab.com/YOUR_USERNAME/proof-engine.git cd proof-engine - Build the project and run a demo:
On Linux, install the ALSA headers first:
cargo build --all-targets cargo run --release --example hello_glyph
sudo apt install libasound2-dev pkg-config.
- Rust: Stable toolchain (edition 2021)
- Dependencies: OpenGL 3.3+, system audio (via cpal/rodio)
- IDE: Any editor with rust-analyzer support recommended
- Open an issue on GitLab with a clear description
- Include the Rust version (
rustc --version) and OS - Provide a minimal reproduction if possible
- Open an issue with the
enhancementlabel - Describe the use case and expected behavior
- Explain how it fits the engine's mathematical rendering philosophy
-
Create a branch from
main:git checkout -b feature/your-feature-name
-
Write your code following the project conventions:
- All rendering primitives should be mathematically driven
- Prefer
f32math withglamtypes (Vec2,Vec3,Vec4,Mat4,Quat) - Use
stdonly for new subsystems unless an external crate is truly necessary - Keep modules self-contained with clear public APIs
-
Run what CI runs:
cargo build --all-targets sh ci/test-lib.sh # library unit tests, minus the known failures cargo test --test '*' --bins # integration tests cargo test --doc
-
Commit with a clear message:
git commit -m "Add: brief description of what was added" -
Push and open a Pull Request against
main
- Follow standard Rust formatting (
cargo fmt) - Use
snake_casefor functions and variables - Use
CamelCasefor types and traits - Keep functions focused and reasonably sized
- Add doc comments (
///) for public APIs - Avoid over-engineering: simple and direct is preferred
The engine is organized into self-contained modules under src/:
src/
math/ Core mathematical functions, noise, curves, attractors
render/ OpenGL pipeline, shaders, post-processing
particle/ Particle systems, emitters, flocking
entity/ Amorphous entities, formations, cohesion
physics/ Rigid body, soft body, fluids, constraints
scene/ Scene graph, spatial indexing, portals
audio/ Synthesis, DSP, spatial mixing
scripting/ Lua-like VM, compiler, stdlib
ecs/ Entity Component System
ui/ Widget toolkit, layout, panels
...and more
Each module should:
- Have a
mod.rswith public re-exports - Be independently compilable (no circular dependencies)
- Include unit tests in
#[cfg(test)]blocks
- Add tests for new functionality in the same file or a
testssubmodule - Run the suite before submitting:
sh ci/test-lib.sh, thencargo test --test '*' --binsandcargo test --doc. - A plain
cargo test --libcurrently reports failures: the tests named inci/known-failing-tests.txtfail onmainand CI skips exactly those. Fixing one is a good first contribution: make it pass, delete its line from the file, and say in the PR whether the code or the test was wrong.sh ci/run-known-failing.shruns only those tests. - Tests must not need a window, a GPU or an audio device; CI has none of them.
- Performance-sensitive code should have benchmarks in
benches/
- New mathematical primitives: curves, surfaces, fractals, simulations
- Rendering improvements: new post-processing effects, shader techniques
- Performance: SIMD optimizations, better algorithms, GPU compute kernels
- Game systems: AI, networking, procedural generation
- Documentation: examples, tutorials, API docs
- Bug fixes: correctness, edge cases, platform compatibility
- Breaking changes to public APIs without discussion
- Adding heavy external dependencies without justification
- Code that doesn't follow the mathematical rendering philosophy
- Placeholder or stub implementations (write real logic)
Be respectful, constructive, and welcoming. We're all here to build something cool with math.
By contributing, you agree that your contributions will be licensed under the MIT License.
Open an issue or start a discussion on the repository. We're happy to help you get started!