Skip to content

Vulcaaa/Raytracer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Raytracer

A 3D renderer written in C++23 that simulates light propagation using raytracing — rays bounce between surfaces to generate reflections, refractions, shadows and materials. Scenes are described in plain configuration files and rendered to PPM images, with multithreaded rendering via OpenMP.

Features

  • OOP architecture — primitives, lights and materials behind clean interfaces (IPrimitive, ILight, IMaterial), instantiated through factories
  • Plugin system — components are loaded dynamically as shared libraries (DLLoader / PluginFactory), so the renderer can be extended without recompiling the core (see scenes/Plugins_Docu.md)
  • Primitives — spheres, planes, boxes, cones, cylinders, tori, triangles, and .obj mesh loading
  • 3D fractals — Mandelbulb, Menger sponge, Sierpinski, Möbius strip, tangle cube
  • Materials — Lambertian, Phong, reflective, refractive, and textures
  • Lights — point, directional and ambient lighting
  • Scene description — human-readable .cfg files parsed with libconfig++; change a scene without recompiling
  • Multithreading — parallel rendering with OpenMP when available
  • Sample scenes — point-light, primitive and fractal demos in scenes/

Build

Requires CMake, a C++23 compiler, and libconfig++ (fetched automatically if missing). OpenMP is used when available.

cmake -B build
cmake --build build

Usage

./raytracer <scene.cfg>

The render is written to output.ppm. Example:

./raytracer scenes/scene_pointlight.cfg

A scene file describes the renderer settings, camera, materials, lights and primitives. See scenes/ for ready-to-use examples and scenes/Plugins_Docu.md for the scene/plugin format.

Credits

Team project realized as part of the Epitech curriculum — OOP module.

  • Nielsen Combe-Bracciale
  • Mathys Aberkane
  • Sefkan Aydogdu
  • Julie Vincent

About

A 3D renderer in C++23 that simulates light propagation via raytracing — reflections, refractions, shadows, materials, fractals, and a plugin architecture.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors