
Explore modern OpenGL programming to create hardware-accelerated 2D and 3D graphics with shaders and the core profile, understanding rendering from data to pixels.
Throughout the course you will be writing the code that demonstrates the current lesson. Each lesson builds upon the last. We will write every single line of code together starting with a blank project. We will start writing the code in the next lesson. The final lesson will incorporate everything we learned up to that point. We hope you find this course fun and interesting and above all we hope you learn a foundation of how to program using the modern OpenGL API. Let's get started!
Create a modern OpenGL window with a core profile, initialize glue, handle keyboard input, enable double buffering, and display frames per second in the window title.
Explore rendering a triangle in modern OpenGL by organizing the project, creating a vertex buffer object and a vertex array object, and writing vertex and fragment shaders.
Develop a reusable shader class to load, compile, and link vertex and fragment shaders using glsl, explore uniforms, and follow the OpenGL graphics pipeline from vertices to pixels.
Learn how texture mapping adds detail by wrapping a 2D image onto a quad, load textures with stb image, configure wrapping and filtering, and implement a texture class for multi-texturing.
There are no downloads for this lesson.
Learn to render a rotating textured cube in 3d by applying model, view, and projection matrices, enabling depth testing, and setting up a viewport with window resize.
Implement a flexible camera system with an abstract base class and two derivatives, orbit and first-person shooter cameras, delivering view matrices via look at and user input.
Parse an ASCII LBJ/OBJ file to load vertices, texture coordinates, and faces, then build vertex buffers and a vertex array object to render multiple models.
Explore lighting foundations in OpenGL by adding ambient, diffuse, and specular components using Phong and Gouraud models, learn normals handling, directional light, and per-fragment lighting.
Explore implementing ambient, diffuse, and specular lighting with Phong and Blinn-Phong models, including light and material structures, textures, a moving light, and a six-model scene.
Explore directional, point, and spotlight lighting in OpenGL, learn attenuation, ambient lighting, and texture-based shading with diffuse and specular components.
This course will introduce you to modern OpenGL programming. We will teach you a brief history of OpenGL to help you understand why we chose to teach modern OpenGL with its programmable rendering pipeline over the fixed function pipeline. The majority of tutorials and books only teach the outdated versions of OpenGL API with its fixed function pipeline. We will show you how to use the faster, more efficient and more flexible OpenGL API.
We begin with the basics of getting OpenGL running in a window using the GLFW library. Then we will move on to understanding the basics of rendering polygons to the display by sending buffers of data to the computers graphics card and programming it using shaders with the GLSL shading language. We learn how to map textures to our objects. We'll set up a virtual camera using keyboard and mouse inputs to enable us to move around in the scene.
After we have the fundamentals working then we can start building more complex things. We will learn how to load 3D models and add interesting lighting to the scene. By the end of this course, you will know how to set up and render in 3D with modern OpenGL. With each lesson we build the framework with reusable C++ and OpenGL code. That is a great starting place for you to build your own game engine. We will start with a blank project and write code each step of the way and each lesson builds upon the last. Even if you have never touched OpenGL you should find the course easy to follow and everything explained along the way. All of the source code, pre-built third party libraries and Visual Studio solutions for each lesson are included.