A simple pathtracer.
# clone repo
git clone git@github.com:mps0/pt.git
# get minifb module
git submodule update --init
# build folder
mkdir build && cd build
# configure and build
cmake .. && cmake --build .# NEE integrator
./pt nee
# Photonmap integrator
./pt photonmapFirst render:
Comparing standard path tracing with photon mapping:
Standard path tracing:
Photonmap:
Care has to be taken with how lights are sampled (directly or indirectly), as well as how photons are shot and how much energy each photon has for the two methods to converge to the same result.
Photonmap Glass:
Gamma Correction: