Skip to content

ashyantony7/WASMImGui

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

WASM Imgui Template project

This is a template project for building a webassembly application using imgui and emscripten.

Setup

The following dependencies must be installed

  1. CMake, Ninja and Conan: These dependencies are handled using pip in requirements.txt. To install them (preferably in a virtual environment) run:
pip install -r requirements.txt
  1. OpenGL:

We use openGL for rendering. The following dependencies must be installed:

  • Mac Os X
brew install glfw3
brew install glew
  1. Emscripten:

Setup a conan profile for emscripten. Save the following file to ~/.conan/profiles/emscripten:

  • Mac Os:
include(default)

[settings]
os=Emscripten
arch=wasm
compiler=clang
compiler.version=16
compiler.libcxx=libc++
build_type=Release

[tool_requires]
emsdk/3.1.23

Build the application:

mkdir build && cd build
conan install ../conanfile.txt  --build missing --profile:build=default --profile:host=emscripten -s build_type=Release
source ./conanbuild.sh
cmake -G Ninja -DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake -DCMAKE_BUILD_TYPE=Release ..
cmake --build . --config Release

About

Template project for ImGui WASM

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published