A real-time rendering demo built from scratch using OpenGL and C++.
- Physically Based Rendering (PBR)
- Image-Based Lighting (IBL)
- Deferred shading
- Screen Space Ambient occlusion (SSAO)
- Sobel edge detection
- Shadow mapping
- Bloom postprocessing
- Minor features: Geometry shader, Blinn-Phong shading, Skybox, glTF model loading.
pbr_tachikoma.mp4
![image](https://private-user-images.githubusercontent.com/790432/300280953-2cbf021d-9b2d-42f8-afb2-965a538d1640.jpg?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQyODYwMTcsIm5iZiI6MTcyNDI4NTcxNywicGF0aCI6Ii83OTA0MzIvMzAwMjgwOTUzLTJjYmYwMjFkLTliMmQtNDJmOC1hZmIyLTk2NWE1MzhkMTY0MC5qcGc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwODIyJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDgyMlQwMDE1MTdaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT02NTMxNGUzMTMxMTY4ZjVjNWNjN2E5Y2Y5NGM2YmVlM2ViZGMyMTk1YTc1ZmI3NjUyYTc5MWViOWUxZDdjOTQ4JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.I3T4kwSZQjuxhBb4jhtjTSLgE5sKy1L3WbkvvocQvk4)
A Sponza scene with 300 light sources.
deferred_shading.mp4
This Gundam model looks great with ambient occlusion.
![image](https://private-user-images.githubusercontent.com/790432/287473855-a5a9ae9e-a544-469c-b159-90a3bd94ca25.png?jwt=eyJ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EyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwODIyJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDgyMlQwMDE1MTdaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0wNzkxMGQzMzUzM2JhYjgwMDg2ZTU0NTk1ZjEyNmYwMmVkN2VkNmIwYTU0ZjZjMDkxY2RiNmQzNGM5ZWIwM2E1JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.YikxVBO_Wdad8sE7ukoH2YxdEJuxH5e2dMoylsiOneA)
The sahdow edges are blurred using PCF.
shadow_mapping.mp4
![image](https://private-user-images.githubusercontent.com/790432/290675096-caa5006f-f31d-4174-941f-ce530785b52d.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQyODYwMTcsIm5iZiI6MTcyNDI4NTcxNywicGF0aCI6Ii83OTA0MzIvMjkwNjc1MDk2LWNhYTUwMDZmLWYzMWQtNDE3NC05NDFmLWNlNTMwNzg1YjUyZC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwODIyJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDgyMlQwMDE1MTdaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1jZTE2YWU0ZDYyOWQzNjI5OGIxNzdjZmU2ZTBkNDUzNmJiNmM0MDQ5OTIwOGU3Y2ViN2RkM2FmOTE2Mjc0MGZlJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.tWq9M3vdxkCoc3zdsTi4OoPcd3ckfixksWsVpfovxO8)
![image](https://private-user-images.githubusercontent.com/790432/290333041-da456381-d72f-481f-8c70-2592a98e1c3d.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQyODYwMTcsIm5iZiI6MTcyNDI4NTcxNywicGF0aCI6Ii83OTA0MzIvMjkwMzMzMDQxLWRhNDU2MzgxLWQ3MmYtNDgxZi04YzcwLTI1OTJhOThlMWMzZC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwODIyJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDgyMlQwMDE1MTdaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT03MDEzMzAzODJmYmQ1M2IzYmM5NjJhNTZhYjJkNTZmZTNiNTY3ODlkMmRiYzAzNTAwNDgwOWFmNDM3MzBiYTk5JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.-4-k3qAmP2mjsYy0BnXzGc8-sZEqVsh7YPcIUhEX4FY)
pbr_armor.mp4
pbr_helmet.mp4
![image](https://private-user-images.githubusercontent.com/790432/287380929-9d3efcf9-bea8-4562-a200-db6ace329e85.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQyODYwMTcsIm5iZiI6MTcyNDI4NTcxNywicGF0aCI6Ii83OTA0MzIvMjg3MzgwOTI5LTlkM2VmY2Y5LWJlYTgtNDU2Mi1hMjAwLWRiNmFjZTMyOWU4NS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwODIyJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDgyMlQwMDE1MTdaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT03N2NhNDBlNzFhMjdmODU0MmVlZTIzZDQ2ZTI1YWIzNGY3ZmM5MzJlYTBhMTkyZTY4NmZjZjUyODA4ZDgxOWUyJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.peeI-oGQmGHdT5WbTGEB90DQgZVU8PHPsK_rruEjmy8)
- OpenGL 4.6 / Direct State Access
- Visual Studio 2022 x64 and C++20
- Libraries: Assimp, glad, glfw, glm, assimp, ImGui, and stb.
Technical Resources:
Assets:
3D Models: