11// clang format will change the input order which MUST be in this specific
22// order
33// clang-format off
4- #include < glad/gl.h>
5- #include < GLFW/glfw3.h>
4+ #include " glad/gl.h"
5+ #include " GLFW/glfw3.h"
66// clang-format on
77
88#include < chrono>
99#include < filesystem>
1010#include < format>
11- #include < glm/gtc/matrix_transform.hpp>
1211#include < iostream>
1312
1413#include " glm/ext/matrix_clip_space.hpp"
15- #include " model.h"
16- #include " shader.h"
17- #include " window.h"
18-
14+ #include " glm/gtc/matrix_transform.hpp"
1915#include " imgui.h"
2016#include " imgui_impl_glfw.h"
2117#include " imgui_impl_opengl3.h"
18+ #include " model.h"
19+ #include " shader.h"
20+ #include " window.h"
2221
2322int main (int argc, const char ** const argv) {
2423 if (argc != 2 ) {
@@ -37,11 +36,16 @@ int main(int argc, const char** const argv) {
3736 IMGUI_CHECKVERSION ();
3837 ImGui::CreateContext ();
3938 ImGuiIO& io = ImGui::GetIO ();
40- io.ConfigFlags |= ImGuiConfigFlags_NavEnableKeyboard; // Enable Keyboard Controls
41- io.ConfigFlags |= ImGuiConfigFlags_NavEnableGamepad; // Enable Gamepad Controls
39+ io.ConfigFlags |=
40+ ImGuiConfigFlags_NavEnableKeyboard; // Enable Keyboard Controls
41+ io.ConfigFlags |=
42+ ImGuiConfigFlags_NavEnableGamepad; // Enable Gamepad Controls
4243
4344 // Setup Platform/Renderer backends
44- ImGui_ImplGlfw_InitForOpenGL (window.GetWindow (), true ); // Second param install_callback=true will install GLFW callbacks and chain to existing ones.
45+ ImGui_ImplGlfw_InitForOpenGL (
46+ window.GetWindow (),
47+ true ); // Second param install_callback=true will install GLFW
48+ // callbacks and chain to existing ones.
4549 ImGui_ImplOpenGL3_Init ();
4650
4751 Model model = Model (model_path);
@@ -114,7 +118,8 @@ int main(int argc, const char** const argv) {
114118 if (ms_elapsed > FPS_REPORT_INTERVAL_MS) {
115119 float fps = frames_displayed / (ms_elapsed / 1000 .0f );
116120 std::cout << std::format (
117- " [renderer2] {:.1f} FPS | {} vertices | {} triangles | {} meshes\n " ,
121+ " [renderer2] {:.1f} FPS | {} vertices | {} triangles | {} "
122+ " meshes\n " ,
118123 fps, vertex_count, triangle_count, mesh_count);
119124 frames_displayed = 0 ;
120125 past_time = std::chrono::steady_clock::now ();
0 commit comments