Skip to content

Latest commit

 

History

History
33 lines (20 loc) · 1.31 KB

README.md

File metadata and controls

33 lines (20 loc) · 1.31 KB

Crab TV

A rasterizing software .obj model renderer written from-scratch in Rust, including implementing primitives like drawing lines and triangles.

It supports textures, normal maps, lighting using a phong shading model, shadows, screen space ambient occlusion, and glow maps:

output

Here's a slower-paced video that also shows off some more of the earlier and intermediate steps, such as wireframe rendering, flat shading and shadow mapping:

little-crab-tv-recording.mp4

It roughly follows the overall approach laid out by the C++-oriented Tiny Renderer.

Is raytracing more your jam? Then check out The All Seeing Crab.

Prereqs

  • Rust, obviously
  • eframe dependencies: sudo apt-get install libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev libspeechd-dev libxkbcommon-dev libssl-dev
  • cargo-watch for devloop: cargo install cargo-watch

Developing

cargo watch -x run

That'll run the renderer in debug mode, but if you want to play with it then it's best to run it in release mode so that it doesn't run like molasses:

cargo run --release