AEJuice Free Plugins https://aejuice.com/free-plugins/?ref...
AEJuice I Want It All Bundle https://aejuice.com/product/i-want-it...
AEJuice YouTube Channel / @aejuice
In this video I will introduce you to a basic lighting model in OpenGL called the 'Phong Reflection Model'. We will review the components of this model and implement ambient lighting. We will also start adding material support to our basic mesh and a base light class that we will expand over the course of the next few episodes.
The model of the demo in this tutorial is https://polyhaven.com/a/wine_barrel_01 by James Ray Cock.
Make sure to watch all the previous tutorials in the "OpenGL For Beginners" playlist at • OpenGL for Beginners
Please visit https://ogldev.org to see more of my tutorials on modern OpenGL.
Link to source: https://github.com/emeiri/ogldev/blob...
If you want to get the same version that was used in the video checkout the tag TUT_19_MATERIALS.
OpenGL 4.6 specification: https://www.khronos.org/registry/Open...
Timecodes:
0:00 Intro
0:57 Phong Reflection Model
1:38 Diffuse lighting
2:59 Specular lighting
3:43 Ambient lighting
4:55 Materials
6:40 Todo list
7:33 The lighting equation
9:52 Code review
10:08 The Technique class
11:18 The LightingTechnique class
13:56 Changes to the main application code
14:51 The light source
15:26 The material
18:15 The fragment shader
19:01 Handling uniforms of structures
19:56 The demo model
20:45 The format of OBJ material files
21:35 Test the code
22:12 Fix the Assimp import problem
22:33 A couple of experiments
23:00 Conclusion
Feel free to comment below.
Email: [email protected]
Facebook: / ogldev-188319114585587
GIthub: https://github.com/emeiri/ogldev.git
Twitter: @ogldev
One time donations (Paypal): https://ogldev.org/donate.html
Patreon: / ogldev
My gear (Amazon affiliate links):
Camera - Canon EOS M50: https://amzn.to/3duVIOh
Camera mic - Rode Videomic: https://amzn.to/3dsGVDs
Desktop mic - Rode NT-USB-Mini: https://amzn.to/3giMoif
Credits:
Image: https://computingthehumanexperience.c...
Music: "Photo Album" from https://bensound.com
Enjoy,
Etay Meiri
#opengl #ogldev #opengtutorials