Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Rust Ray Tracer

This is a compact educational ray tracer in one source file that outputs an ASCII PPM image to stdout.

Build & run

cargo build --release
# produce an image (scene 3, 800x600, recursion depth 3)
./target/release/rust_raytracer 3 800 600 3 > output.ppm

Scenes

1 - single sphere 2 - plane + cube (lower brightness) 3 - all objects (sphere, cube, cylinder, plane) 4 - same as 3 but different camera position

Toggle parameters

  • argument 1: scene id (default 3)
  • argument 2: width (default 400)
  • argument 3: height (default 300)
  • argument 4: max recursion depth for reflections (default 3)

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages