Skip to content

Latest commit

 

History

History
31 lines (18 loc) · 883 Bytes

README.md

File metadata and controls

31 lines (18 loc) · 883 Bytes

Raytracer

A simple raytracer, built following The Raytracer Challenge.

Implemented from scratch with zero external dependencies (except for test helpers).

Current progress: it can render a simple scene with spheres, stripe patterns and shadows.

rendered sphere

Run the examples

This project requires rust nightly.

Run an example with:

cargo run --release --example patterns

The rendered image will be saved in the examples/out/ directory in the PPM format.

Implementation notes

Differences from the book

  • There is no concept of tuple: points and vector have their own types
  • Shading supports multiple sources of light

Other notes

  • Matrices and matrix operations are implemented via const generics (where possible)