Overview
The Jar (Just Another Renderer) project is a 3d renderer using the Direct3D 12 API. The current feature set supports a deferred renderer, slang shaders, and a physically based rendering pipeline.
Motivation
Jar is perhaps my 5th renderer I have made in my spare time while attending university. I originally started with OpenGL, which was fun, but I was told that Direct3D was where developers are using in the industry. I used Direct3D 11 for both a small engine and a renderer as well before moving onto Direct3D 12.
I was inspired MJP's and Kostas Anagnostou's blogs that detail on graphics, mainly around Direct3D to write more to share my own thoughts, but also just experimenting more.
Technical Challenges
I struggle with code architecture and making sure that all data I commit to creating make sense, and ensuring that in a few days I won't forget what I even did at that point. I initially borrows a lot of the architecture from the Microsoft MiniEngine to jump start my project a bit, but since I am not using hlsl, a significant diversion was made early on.
Perhaps I should count myself lucky that Microsoft gave us decent debug messages when something goes wrong during development, and also that MSDN is also quite decent. But despite that, there were many times I had to dig into Pix to inspect what really went wrong. Even trivial problems like byte mismatches took me a long time to find as it was not obvious. Eventually I learned to just put asserts everything to catch these bugs.
Implementation Details
Even though I prefer writing in a more C based C++ way, I tried to use as much modern C++ techniques I can think of on the spot for this project. I heavily used inheritance and the standard library. The books I read have alternative takes on using such language features in a real time software, but I figured that since I am not creating a game, then performance will not be that bad, hopefully.
Even at this stage, I mainly utilized just Microsoft's DX12 helpers and the D3D12MemoryAllocator. Since I decided that I am creating a renderer focused on 3d model presentation, I realize I have to support some sort of material system, scene loading, and undo systems. Right now, I barely implemented a material system, which is just a json file pointing to different directory. Not entirely graphics related, but still important as part of software anyway.
Experimenting
The main priority I want to implement soon are visibility buffers. I first noticed this technique in this blog from Filmic Worlds, and later learned about The Forge and their talks on it. Before fully attempting this feature, I do want to go fully bindless for the renderer since right now I am binding a ton throughout my code base.
There are a also lots of other features that I am still actively developing towards. One I am looking forward to is mesh shader. Work graphs are interesting but read that it might not beat ExecuteIndirect performances? Always will be curious about different graphics pipelines to reach the same goal. I know going through the input assembler, to geometry, to pixel shader, to output merger is quite old but works great, so seeing techniques that differ is definitely interesting.
