Protoni's site

OpenGL experiments

July 27, 2020 - category: graphics

I was doing this OpenGL course on Udemy a while ago and here is the progress so far.

Got a window open.

Had to setup first:

  • Microsoft Visual Studio 2019
  • GLEW ( OpenGL Extension Wrangler )
  • GLFW ( OpenGL FrameWork )
  • Code to init GLEW and GLFW

Window open

Got a triangle to the screen šŸ˜€

Triangle

Triangle moving

Triangle moving

Interpolate

Triangle got some color and a z axis. The GIF looks a bit weird on this one.

Triangle rotating

Camera

Camera, keyboard and mouse control added.

Camera

Texture

Texture loading done using stb_image.h loader. Also forgot to mention earlier that Iā€™m using math library called glm.

Textures

Lighting

Got some lights going on.

  • Directional lights
  • Ambient lighting
  • Diffuse lighting
  • Specular lighting
  • Point lights

Lights

Spotlight following a camera.

Spotlight

Model importing

Random models from https://free3d.com Model importing

Orgrimmar from World of Warcraft

Links:


Written by protoni. Contact at toni@protoni.fi