Skip to content

ImGui Program

We can use add_requires to add imgui dependency to use ImGui. We can also enable glfw_opengl3 config to use GLFW+OpenGL3 backend.

EXPLORER
src
main.cpp
xmake.lua
Lua xmake.lua
12345678910
add_rules("mode.debug", "mode.release")

add_requires("imgui", {configs = {glfw_opengl3 = true}})
add_requires("glfw", "opengl")

target("test")
    set_kind("binary")
    add_files("src/*.cpp")
    add_packages("imgui", "glfw", "opengl")
    set_languages("c++11")