This project explores implementing a raytracer that is not tied to acceleration structures from a specific vendor. Most modern raytracers are accelerated with NVIDIA's OptiX technology, which limits users to machines with an NVIDIA GPU. However, with the advent of arbitrary GPU kernels (CUDA, HIP, etc.) and new universal device standards (SYCL), it is possible to write hardware-agnostic code that can take advantage of any variety of GPU if one exists.
At the core of this project is SYCL, a standard developed by Khronos that defines a common framework for offloading repetitive operations to devices that support parallel computing. Many implementations of the SYCL standard exist, but this project uses AdaptiveCpp due to its open-source nature. There are many benefits to using SYCL over device-specific code:
- Hardware Agnostic: the SYCL standard supports many varieties of GPUs, and other parallelism models as well
- Future Compatible: new devices can become compliant with the SYCL standard
- Modern C++: much of CUDA resembles pre-11 C++, and using APIs like Vulkan or DirectX require additional shading languages (GLSL, HLSL, etc.)
- Open Source: AdaptiveCpp is an open-source implementation of the SYCL standard