Path tracer written in Golang
This project is a Monte Carlo path tracer written in Golang that runs on CPU.
For now, scene has to be set in main.go
file, I'm planning to add support for reading scenes from files in the future.
This program has only one external dependency, it's hdr library, to install it, run the following command:
go get github.com/mdouchement/hdr
If you're not planning to use HDRI environment maps, remove the following line from the top of main.go
file:
_ "github.com/mdouchement/hdr/codec/rgbe"
To run the program, type the following command:
go run .
Some of the models downloaded from Morgan McGuire's Computer Graphics Archive. The Go gopher was designed by Renee French. (http://reneefrench.blogspot.com/). The gopher 3D model was made by Takuya Ueda (https://twitter.com/tenntenn). HDRI image used in one of the examples was downloaded from HDRI Haven. Textures used in one of the examples were downloaded from TextureCan and Texture Haven.
Mori knobs - rough copper, rough glass, glossy plastic
A scene with Nishita sky model with sun (denoised in Blender)
Render of a scene with materials with different level on roughness from my path tracer on the left and reference render from Blender on the right
Four spheres with different textures and materials with HDRI environment map
Cornell box with mirror box