Skip to content
SALAH-NAMEPublic

About

A ray tracing written in C.

Resources

Stars

1 star

Watchers

1 watching

Forks

Latest commit

 

History

97 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MiniRT

A raytracer written in C. Renders spheres, planes, cylinders, and cones with lighting, shadows, and bonus features like specular highlights, checkerboard patterns, and bump maps.


Build & Run

make                          # mandatory parser
make bonus                    # bonus parser (specular, checker, cones)

./miniRT scenes/scene.rt
./miniRT_bonus scenes/scene.rt

Controls

Key Action
1/2/3/4 Switch mode: object move / object rotate / camera move / camera rotate
W A S D Move horizontally
↑ ↓ Move vertically
Tab Select next object
T Toggle render mode
Esc / Q Quit

Scenes


Solar System

Cornell Box

Sphere Cube

Chess Pawns

Neon Corridor

Sea of Spheres

Scene Format

A 0.2 255,255,255               # ambient: ratio R,G,B
C 0,0,20 0,0,0 70               # camera: pos orient(euler) fov
L 5,10,5 0.8                    # light: pos brightness

sp 0,0,0 2 255,100,50           # sphere: pos radius color
pl 0,-1,0 0,1,0 200,200,200     # plane: pos normal color
cy 0,0,0 0,1,0 1 4 100,150,255  # cylinder: pos axis radius height color

About

A ray tracing written in C.

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages