Skip to content

A raytracer written in Rust. Based on "The Ray Tracer Challenge" by Jamis Buck

License

Notifications You must be signed in to change notification settings

guydunton/rtracer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

38 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RTracer

Rust GitHub

A ray tracer build in Rust from the excellent book "The Ray Tracer Challenge" by Jamis Buck (Link).

The project renders a static scene like the one below. When rendering is complete the scene is saved as a out.png into the working directory:

Results of chapter 9 in the rtracer window

See below for the results at the end of each chapter.

Build, Run & Test

The project just uses Cargo to build & run:

cargo build # Build the code in debug mode
cargo run   # Run the code
cargo test  # Run the unit tests

Results of each chapter

Chapter Description Image
1 - 4 Background maths for tuples, matrices & colors N/A
5 Flat color rendering Results of chapter 5
6 Add lighting and shading Results of chapter 6
7 Creating a complex scene from spheres Results of chapter 7
8 Adding shadows Results of chapter 8
9 Adding planes for the background Results of chapter 9

About

A raytracer written in Rust. Based on "The Ray Tracer Challenge" by Jamis Buck

Topics

Resources

License

Stars

Watchers

Forks

Languages