Game engines always fascinated me, but I was lacking knowledge about the fundamental principles that make 3D graphics appear on the screen. Therefore, I decided to start from scratch and learn the basics, in this case through OpenGL.
The current version features the implementation of an OpenGL renderer (using the core profile, version 3.3 as of now).
Vector- (dot- and cross-product) and matrix operations
Coordinate spaces (model-, view-, projection-matrix)
Controllable flythrough camera
Phong shading
Lighting with a directional light, point lights and a spotlight
UI to control light and material properties at runtime using Dear ImGUI
Event based keyboard and mouse input through GLFW
Import of 3D models stored in various formats, including support for binary glTF 2.0 files with embedded textures through Assimp
Cross-platform (compiled for Windows and Linux)
The source code and builds are available on GitHub: https://github.com/saschabrunner/OGLR
I built this renderer based on the contents of the learnopengl.com website by Joey de Vries. It represented a very useful resource to me, explaining all the basic principles behind 3D graphics, including the maths and ideas required to bring basic points in space through the coordinate spaces onto screen, texture faces and add lighting.
With my extensive C and moderate C++ knowledge prior, I set myself out to add to the provided code samples. As an exercise to myself, I used many of the unique C++ features to improve my C++ knowledge substantially.