Apsen is a forward rendered 3D Real-Time Ray Traced graphics renderer written in C++ using Vulkan.
This project was done to explore the Vulkan API and learn more about the underlying graphics hardware and pipeline systems in place to perform rasterization and ray tracing rendering.
This is not intended to be an engine, just a graphics renderer using rasterization and ray tracing.
Note: This project is currently targeting Windows platforms only.
First, clone the repository using:
git clone --recursive https://github.com/EmreDogann/Aspen-Renderer.git
If you cloned the repository non-recursively before then run the command below to clone the submodules:
git submodule update --init
The following must be installed:
- CMake (v3.21+) - I recommend the
Windows x64 Installer
as it can automatically add its /bin folder to the system PATH environment variable, otherwise you will have to do this manually with the .zip version - Vulkan SDK (v1.2.189.2+) - Recommended to install in the default location. Use the
SDK Installer
instead of the runtime/zip file. - MinGW-w64 (Read Below)
There are two different ways to download MinGW-w64:
- MinGW-w64 Standalone Build - I've tested it with the Release Version, UCRT Runtime, 11.2.0 Win64 build.
This is a standalone build created by Brecht Sanders. This is the easier/quicker way as all you need to do is download the .7z/.zip, extract it to a folder somewhere on your system, then add the path of your mingw64/bin
folder to your environment PATH variable.
OR
This provides you with an up-to-date version of GCC for Windows. The process to install it is slightly more involved than the first option, but this method can act as a package manager for keeping GCC up-to-date along with other packages you decide to install through it.
Once again, after following all the installation instructions, don't forget to add the path to the msys64/mingw64/bin
folder to your environment PATH variable.
To build this project, once all the above requirements have been met, go through the following:
cd ./Aspen-Renderer/
mkdir ./build
cd ./build/
cmake .. -G "MinGW Makefiles"
cmake --build . --config Release
After this there should be a aspen-vulkan-renderer.exe
executable in the /builds
folder. Running that executable will start up the renderer.
- GLFW - For platform-specific window management.
- GLM - For Maths computations used for rendering.
- EnTT - Used for implementation of an ECS.
- ImGui - Used for UI (docking branch is used).
- ImGuizmo - Used for gizmos.
- Tinyobjloader - Used to load .obj models.
- stb_image - Used to load images from a file/memory.
Some code samples/system design for this project was adapted from:
- Brendan Galea's Vulkan Game Engine Series - Used as basis for the design of the renderer.
- The Cherno's Hazle Engine - Event system, Entity Component System design.
- Vulkan Tutorial (By Alexander Overvoorde) - Vulkan theory and boilerplate.
- Sasha Willems' Vulkan Samples - Base classes such as Buffer and Framebuffer.