10 releases

Uses old Rust 2015

0.0.9 Jun 27, 2018
0.0.8 Jun 25, 2018

#987 in Graphics APIs

Download history 3/week @ 2024-06-26 4/week @ 2024-07-03 6/week @ 2024-07-24 5/week @ 2024-07-31 1/week @ 2024-08-28 20/week @ 2024-09-18 41/week @ 2024-09-25 3/week @ 2024-10-02

64 downloads per month
Used in pxl-build

CC0 license

29KB
572 lines

pxl

A simple framework for writing graphical programs and games in Rust.

Crates

This repository is a cargo workspace consisting of a number of crates:

  • pxl: The library and runtime. Start here!
  • pxl-build: A compile-time resource loader. Check this out if you want to use static assets, like images and sounds.
  • pxl-build-test: Tests and usage example for pxl-build.
  • pxl-mono: Mono and sometimes chromatic audio-reactive visuals built using pxl

Building

Since pxl programs use per-pixel rendering, building in release mode can yield dramatically improved performance. Do cargo run --release to build in release mode.

Dependencies

The pxl runtime plays audio using cpal, which requires ALSA headers/libraries on Linux;

On Ubuntu, you can install them with:

sudo apt install libasound2-dev

lib.rs:

pxl

A simple framework for making graphical programs in Rust. pxl is intended to avoid Rust's most challenging concepts, while still providing a compelling platform upon which to develop graphical games and programs.

Features

  • Pixel-based rendering
  • Sample-based audio synthesis
  • Custom vertex and fragment shaders
  • pxl-build, a compile-time resource loading crate
  • Action and text input

Dependencies

~3–12MB
~161K SLoC