This is a repo of simple benchmarks across different rendering solutions. Check out the different branches to test.
To build:
cargo watch -i "pkg/*" -s "wasm-pack build"
- In a separate terminal, from the project root:
cd www && yarn && yarn start
- Navigate to
localhost:8080
in a browser. - Game of life should start.
Different branches to test:
tiny-skia
: Using thetiny-skia
drawing library to render a pixel buffer & using shared memory to access across JS and Rust.homemade-pixel-renderer
: Manually managing a pixel buffer in Rust, sharing with JS.piet
: Using thepiet
andpiet-web
libraries, which emits JS to render but is written in Rust.js-renderer
: Canvas-only renderer, just using Rust to manage board state.
Built using wasm-pack-template