From e3b5c13df66eae89f1c3bcc113b10e8c18433833 Mon Sep 17 00:00:00 2001 From: Fox Caminiti Date: Sat, 23 Jul 2022 14:27:07 -0400 Subject: add imgui as submodule --- .gitmodules | 4 ++++ build.sh | 4 +++- imgui | 1 + main.cpp | 14 +++++++------- 4 files changed, 15 insertions(+), 8 deletions(-) create mode 100644 .gitmodules create mode 160000 imgui diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..76917ac --- /dev/null +++ b/.gitmodules @@ -0,0 +1,4 @@ +[submodule "docking"] + path = imgui + url = https://github.com/ocornut/imgui + branch = docking diff --git a/build.sh b/build.sh index fc0232f..df94d61 100755 --- a/build.sh +++ b/build.sh @@ -1,6 +1,6 @@ #!/bin/bash -WINDOWS=1 +WINDOWS=0 if [[ "$WINDOWS" == 1 ]]; then @@ -73,6 +73,8 @@ else SDL_ARGS="`sdl2-config --cflags` -lGL -ldl `sdl2-config --libs`" fi +# imgui + if [[ "$WINDOWS" == 1 ]]; then clang++ $WARNING_FLAGS -g -target x86_64-pc-windows-gnu -march=x86-64-v3 -I .. -Iimgui -Iimgui/backends \ main.cpp imgui/imgui*.cpp imgui/backends/imgui_impl_sdl.cpp imgui/backends/imgui_impl_opengl3.cpp \ diff --git a/imgui b/imgui new file mode 160000 index 0000000..cb8ead1 --- /dev/null +++ b/imgui @@ -0,0 +1 @@ +Subproject commit cb8ead1f7198924f97e52973d115e1d4eaeda2f3 diff --git a/main.cpp b/main.cpp index ff9dc22..c5605c3 100644 --- a/main.cpp +++ b/main.cpp @@ -316,13 +316,13 @@ int main(int argc, char *argv[]) { ui UI = {}; - File.NumberOfSources = 2; - File.Source[0] = (char *)AllocateMemory(&Memory, STRING_SIZE, F_Strings); - File.Source[1] = (char *)AllocateMemory(&Memory, STRING_SIZE, F_Strings); - sprintf(File.Source[0], "../asset/b.jpg"); - sprintf(File.Source[1], "../asset/24.mp4"); - CreateLayerFromSource(&File, &State, &Memory, File.Source[0]); - CreateLayerFromSource(&File, &State, &Memory, File.Source[1]); + // File.NumberOfSources = 2; + // File.Source[0] = (char *)AllocateMemory(&Memory, STRING_SIZE, F_Strings); + // File.Source[1] = (char *)AllocateMemory(&Memory, STRING_SIZE, F_Strings); + // sprintf(File.Source[0], "../asset/b.jpg"); + // sprintf(File.Source[1], "../asset/24.mp4"); + // CreateLayerFromSource(&File, &State, &Memory, File.Source[0]); + // CreateLayerFromSource(&File, &State, &Memory, File.Source[1]); #if 1 // shm_unlink("/testl"); -- cgit v1.2.3