T2.5 [opt] Pyramid and interactive rotation with keyboard

We can also draw a pyramid

Pyramid data

you will get

GLFW key_callback

Write GLFW key call back in main.cpp to interactively change rotation angles

Set key_callback

In main(), add one line after glfw window creation

Now you can play rotating the pyramid with the arrow keys.

Last updated