Full screen with random SSAO samples

There we are! The last missing piece was to remove the aliasing that was apparent due to the regularity of the sampling we were doing on every surface fragments. To solve this, a simple method is to rotate the samples around the surface normal of the fragments. That random rotation is calculated (in my case) with shader code applied on the X and Y coordinates of the current fragment (re-using online code snippets).

Finally, to help debug this better (and to show it off now that it is finally working!!!) I added code to switch to a full screen, mouse controlled, camera by pressing enter. Again, this was simple to add, thanks to the quality object oriented design of the project. The feature proved useful since SSAO is subtle. Thus, having a way to zoom in on the models while refreshing the shader code was very valuable:

Full screen rendering of BRDF with 128 SSAO samples

Lots of effort, for a subtle effect... (toggle on/off visible at the 11 and 14 seconds mark)

Time spent for this Time spent so far
5 h 180 h

SSAO support

Finally, I added SSAO (Screen Space Ambient Occlusion) support after 40h of work! It was my first time implementing it, so it took quite a while. I was very close for a long time, but some tricky parts eluded me. I think it was made more complicated for me because of the multi-viewport setup I have. The matrices I used to render to a part of the viewport where incorrect, but it only appeared when I started using them for SSAO. Finding this was quite tricky (especially when you have to come back to this after working all day on something completely different!).

Anyway, here are the results:

If you want some explanation about what is SSAO, you will have to read further!

Time spent for this Time spent so far
40 h 175 h
[Lire]

Render to texture and model cleanup

I did a bit of grunt work as I was getting frustrated with the look of the scene and the usability of the software while working on rendering. This implied a rework of many models making them more colorful, better optimized (removed duplicate vertices and fixed normals) and standardized (they all face the same directions -Z). I could then update my code to work in a more standard way now that models have been oriented properly. I also added a separate debug camera (in the top left corner), and the necessary code to render to texture (which is now displayed on the platform screens).

New models, better debug experience, first steps for deferred renderin

Surface normals visible on the platform screens after pre-calculation

Time spent for this Time spent so far
15 h 135 h
[Lire]