make include headers only

This commit is contained in:
2025-03-31 13:49:00 -05:00
parent 22350ed54d
commit 121fba5930
11 changed files with 167 additions and 215 deletions

View File

@@ -12,7 +12,7 @@ TestImgui::TestImgui(void* h, Archimedes::App* a) : Archimedes::GuiModule(h, a)
}
TestImgui::~TestImgui() {
window->getRenderer().removeRenderCmd(rcmd);
windowModule->removeRenderCmd(rcmd);
ImGui_ImplOpenGL3_Shutdown();
ImGui_ImplGlfw_Shutdown();
ImGui::DestroyContext();
@@ -20,10 +20,6 @@ TestImgui::~TestImgui() {
void TestImgui::onLoad() {
createWindow();
window->getRenderer().init();
IMGUI_CHECKVERSION();
ImGui::CreateContext();
ImGuiIO& io = ImGui::GetIO(); (void)io;
@@ -38,10 +34,10 @@ void TestImgui::onLoad() {
//ImGui::StyleColorsLight();
// Setup Platform/Renderer backends
ImGui_ImplGlfw_InitForOpenGL(window->getWindowImpl().getWindow(), true);
ImGui_ImplOpenGL3_Init("#version 130");
ImGui_ImplGlfw_InitForOpenGL(windowModule->getWindowImpl().getWindow(), true);
ImGui_ImplOpenGL3_Init("#version 330");
rcmd = window->getRenderer().addRenderCmd([](){
rcmd = windowModule->addRenderCmd([](){
ImGui_ImplOpenGL3_RenderDrawData(ImGui::GetDrawData());
/*if (ImGui::GetIO().ConfigFlags & ImGuiConfigFlags_ViewportsEnable)
@@ -51,7 +47,6 @@ void TestImgui::onLoad() {
}*/
});
//cmdlist.push_back(it);
}
void TestImgui::run() {
@@ -66,9 +61,4 @@ void TestImgui::run() {
ImGui::Render();
if(window->shouldClose())
app->end();
window->doFrame();
}