Practical sessions
Here are some additional suggestions to implement after you have finished reading:
- Adjust the ImGui window properties by using the window flags to disable properties such as the collapsing of the window, or the movement of it, and watch the result. You can find all supported flags in the
imgui.h
file. - Change the checkbox to enable or disable vertical sync. This may be a bit tricky, as the
UserInterface
class may have no direct access to all the data you need. One idea to achieve this VSync change is toggling a Boolean variable in theOGLRenderData
struct as a flag when the checkbox has been clicked and handling the change of this flag in thedraw()
method of the renderer. - Add additional output to the ImGui window, such as the contents of the perspective and view matrix. You have to move them to the
OGLRenderData
/VkRenderData
struct to access them from theUserInterface
class. GLM has aglm::to_string()
function, which works likestd::to_string(...