8000 SDL/imgui at imgui · heydwdev/SDL · GitHub
[go: up one dir, main page]

Skip to content
< 8000 div data-component="SplitPageLayout.Content" class="prc-PageLayout-ContentWrapper-gR9eG">

Latest commit

 

History

History
 
 

imgui

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

ImGui

Demonstrates integrating ImGui using the SDL3 backend.

The build does not work for wasm32-emscripten-none failing at the link step. wasm-ld: error: /zig-examples/imgui/.zig-cache/o/8a796ab18c5dd51def36cd228a9b9f37/libimgui.a(/zig-examples/imgui/.zig-cache/o/79254e1ef1366a43ec6946b90686bf15/application.o): undefined symbol: typeinfo for std::__1::bad_function_call wasm-ld: error: /zig-examples/imgui/.zig-cache/o/8a796ab18c5dd51def36cd228a9b9f37/libimgui.a(/zig-examples/imgui/.zig-cache/o/79254e1ef1366a43ec6946b90686bf15/application.o): undefined symbol: std::__1::bad_function_call::~bad_function_call() wasm-ld: error: /zig-examples/imgui/.zig-cache/o/8a796ab18c5dd51def36cd228a9b9f37/libimgui.a(/zig-examples/imgui/.zig-cache/o/79254e1ef1366a43ec6946b90686bf15/application.o): undefined symbol: vtable for std::__1::bad_function_call

Uses castholm/SDL to build SDL3 from source.

Building

Requires Zig 0.14.0 or 0.15.0-dev (master).

# Run the game
zig build run

# Cross-compile for Windows
zig build -Dtarget=x86_64-windows-gnu -Doptimize=ReleaseFast

# Cross-compile for Linux
zig build -Dtarget=x86_64-linux-gnu -Doptimize=ReleaseFast

# Build for the Web (requires Emscripten)
embuilder build sysroot
zig build -Dtarget=wasm32-emscripten-none -Doptimize=ReleaseFast --sysroot "$(em-config CACHE)/sysroot"
0