RayTrayCpp2 is a Ray Tracing application written entirely using the experimental C++ alternative syntnax: Cpp2.
The goal of this personal project is to showcase and experiment with Cpp2. I am trying to make it as Cpp2-idiomatic as possible, though I think we are still discovering what that means.
To build this project you will need Modern CMake's cppfront Wrapper. You will need to provide the cppfront_DIR
to CMake. I am currently using cppfront with the following flags:
-in
to avoid modules for the time being-no-s
because disabling bounds-checking yielded a 20x speedup. Also currently it is not possible to index arrays in a consteval context, even when both the size of the array and the index are known constants.- Currently definitely lacks proper namespacing
-
This implementation follows the Ray Tracing In One Weekend tutorial.
-
This project is inspired by mraylib.
-
A fresh take on C++ evolution: Cpp2
-
Syntax highlighting for Cpp2, massively helpful!