Skip to content

Latest commit

 

History

History
96 lines (76 loc) · 3.76 KB

File metadata and controls

96 lines (76 loc) · 3.76 KB

xImGui

Build

Maven Central Version Static Badge

xImGui is a java binding for C++ dear-imgui.
It uses webidl file to generate java methods with the help of jParser.
It's meant to be small and 1-1 to C++. ImGui::Begin() is ImGui.Begin() and so on.

Supported extensions:

imgui-node-editor
ImGuiColorTextEdit
ImLayout

ImGui current state:

Emscripten Windows Linux Mac Android iOS
⚠️
  • ✅: Have a working build.
  • ⚠️: Have a working build, but it's not ready yet.
  • ❌: Build not ready.

Note:

* Only snapshot builds are currently available. 
* There are 2 ImGui builds. The first contains ImGui only. The second (Ext) contains ImGui with extensions. 

Setup

xImGuiVersion = "-SNAPSHOT"
// Add repository to Root gradle
repositories {
    mavenLocal()
    mavenCentral()
    maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
    maven { url "https://oss.sonatype.org/content/repositories/releases/" }
}

Core module

dependencies {
    implementation("com.github.xpenatan.xImGui:imgui-core:$project.xImGuiVersion")
    implementation("com.github.xpenatan.xImGui:fdx-shared-impl:$project.xImGuiVersion")
    implementation("com.github.xpenatan.xImGui:fdx-gl-impl:$project.xImGuiVersion")     // OpenGL
    implementation("com.github.xpenatan.xImGui:fdx-wgpu-impl:$project.xImGuiVersion")   // WebGPU
    implementation("com.github.xpenatan.xImGui:fdx-vulkan-impl:$project.xImGuiVersion") // Vulkan

    // Extensions
    implementation "com.github.xpenatan.xImGui:imlayout-core:$project.xImGuiVersion"
    implementation "com.github.xpenatan.xImGui:textedit-core:$project.xImGuiVersion"
    implementation "com.github.xpenatan.xImGui:nodeeditor-core:$project.xImGuiVersion"
}

Desktop module

dependencies {
    implementation("com.github.xpenatan.xImGui:imgui-jni:$project.xImGuiVersion")
    implementation("com.github.xpenatan.xImGui:imgui-ffm:$project.xImGuiVersion")

    // Extensions
    implementation "com.github.xpenatan.xImGui:imlayout-jni:$project.xImGuiVersion"
    implementation "com.github.xpenatan.xImGui:imlayout-ffm:$project.xImGuiVersion"
    implementation "com.github.xpenatan.xImGui:textedit-jni:$project.xImGuiVersion"
    implementation "com.github.xpenatan.xImGui:textedit-ffm:$project.xImGuiVersion"
    implementation "com.github.xpenatan.xImGui:nodeeditor-jni:$project.xImGuiVersion"
    implementation "com.github.xpenatan.xImGui:nodeeditor-ffm:$project.xImGuiVersion"
}

TeaVM module

dependencies {
    implementation("com.github.xpenatan.xImGui:imgui-web:$project.xImGuiVersion")

    // Extensions
    implementation "com.github.xpenatan.xImGui:imlayout-web:$project.xImGuiVersion"
    implementation "com.github.xpenatan.xImGui:textedit-web:$project.xImGuiVersion"
    implementation "com.github.xpenatan.xImGui:nodeeditor-web:$project.xImGuiVersion"
}

Build source

  • Requirements: Java 11, mingw64 and emscripten
  • Windows only for now.