Skip to content

Installation

Lucas Dupont edited this page May 11, 2023 · 5 revisions

How to install the raytracer ?

Prerequisite

You need to install make, cmake, libconfig++ & g++ > 11 to compile this project If you want to use graphical part, you also need SFML & zenity

Debian/Ubuntu

sudo apt update
sudo apt install g++ make cmake libconfig-dev libsfml-dev zenity

Fedora

sudo dnf update
sudo dnf install g++ make cmake libconfig-devel SFML zenity

stb_image

You also need to download stb_image (for texture):

cd /tmp
git clone https://github.com/nothings/stb.git
sudo cp stb/stb_image.h /usr/local/include/
rm -r stb

Compile project

First, create build directory

With make

cd build
cmake ..
make
cd ..
./raytracer

With ninja

cd build
cmake -G Ninja ..
ninja
cd ..
./raytracer

Installation script

A script is available for easy installation. You just need to run it with sudo to install all the dependencies.

sudo bash install_dependencies.sh
Clone this wiki locally