5 Commits

Author SHA1 Message Date
0abb860185 update tracy to v0.9.1 2023-03-05 00:11:16 +01:00
22dc949cc5 update stb to latest, reenable perlin noise 2023-03-05 00:04:31 +01:00
196ea7b93b update imgui to v1.89.3 2023-03-04 23:47:18 +01:00
f655da82d5 silence more conversion warnings 2023-03-04 19:38:13 +01:00
d672f8a52c update github ci emscripten to 3.1.32 2023-03-04 19:14:26 +01:00
9 changed files with 20 additions and 31 deletions

View File

@@ -9,7 +9,7 @@ on:
env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Debug
EM_VERSION: 2.0.24
EM_VERSION: 3.1.32
EM_CACHE_FOLDER: 'emsdk-cache'
jobs:

View File

@@ -2,43 +2,31 @@ cmake_minimum_required(VERSION 3.9 FATAL_ERROR)
project(imgui C CXX)
set(CPP_FILES
add_library(imgui
"imgui/imgui.h"
"imgui/imgui.cpp"
"imgui/imgui_draw.cpp"
"imgui/imgui_widgets.cpp"
"imgui/imgui_tables.cpp"
"imgui/imgui_demo.cpp"
"imgui/misc/cpp/imgui_stdlib.cpp"
"imgui_plot_var.cpp"
#"imgui_impl_sdl_gl3.cpp" # very old
#"imgui_impl_sdl.cpp" # old
#"imgui_impl_opengl3.cpp" # old
"imgui/backends/imgui_impl_sdl.cpp"
"imgui/backends/imgui_impl_opengl3.cpp"
)
set(HPP_FILES
"imgui/imgui.h"
"imgui/imstb_rectpack.h"
"imgui/imstb_textedit.h"
"imgui/imstb_truetype.h"
"imgui/misc/cpp/imgui_stdlib.h"
"imgui/misc/cpp/imgui_stdlib.cpp"
"imgui_plot_var.hpp"
"imgui_plot_var.cpp"
#"imgui_impl_sdl_gl3.h" # very old
#"imgui_impl_sdl.h" # old
#"imgui_impl_opengl3.h" # old
"imgui/backends/imgui_impl_sdl.h"
# TODO: seperate backends into libs
"imgui/backends/imgui_impl_sdl2.h"
"imgui/backends/imgui_impl_sdl2.cpp"
"imgui/backends/imgui_impl_opengl3.h"
"imgui/backends/imgui_impl_opengl3.cpp"
)
add_library(imgui ${CPP_FILES} ${HPP_FILES})
target_compile_features(imgui PUBLIC cxx_std_11)
if(MM_OPENGL_3_GLES)

View File

@@ -11,9 +11,8 @@ target_link_libraries(stb_image stb)
add_library(stb_image_write "stb/stb_image_write.h" "stb_image_write.cpp")
target_link_libraries(stb_image_write stb)
# lel TODO: add back in when patent expires
#add_library(stb_perlin "stb/stb_perlin.h" "stb_perlin.cpp")
#target_link_libraries(stb_perlin stb)
add_library(stb_perlin "stb/stb_perlin.h" "stb_perlin.cpp")
target_link_libraries(stb_perlin stb)
add_library(stb_rect_pack "stb/stb_rect_pack.h" "stb_rect_pack.cpp")
target_link_libraries(stb_rect_pack stb)

View File

@@ -10,6 +10,8 @@ if(NOT EMSCRIPTEN)
"${CMAKE_CURRENT_LIST_DIR}/tracy/public/TracyClient.cpp"
)
option(TRACY_ENABLE "Enable tracy profiling" OFF)
if(TRACY_ENABLE)
target_compile_definitions(tracy_client PUBLIC TRACY_ENABLE)
#target_compile_definitions(tracy_client PUBLIC TRACY_NO_SYSTEM_TRACING)

View File

@@ -1,7 +1,7 @@
#include "./imgui_s.hpp"
#include <imgui/imgui.h>
#include <imgui/backends/imgui_impl_sdl.h>
#include <imgui/backends/imgui_impl_sdl2.h>
#ifdef MM_OPENGL_3
#include <imgui/backends/imgui_impl_opengl3.h>

View File

@@ -391,7 +391,7 @@ struct TestStruct {
double f64 {0.};
// float compressed [0; 1] range
constexpr static float c0_f32_resolution = 0.001;
constexpr static float c0_f32_resolution = 0.001f;
constexpr static MM::ScalarRange2<float> c0_f32_r{0.f, 1.f};
float c0_f32_0 {0.f};
float c0_f32_1 {0.f};
@@ -399,7 +399,7 @@ struct TestStruct {
float c0_f32_3 {0.f};
// float compressed [-1; 1] range
constexpr static float c1_f32_resolution = 0.05;
constexpr static float c1_f32_resolution = 0.05f;
constexpr static MM::ScalarRange2<float> c1_f32_r{-1.f, 1.f};
float c1_f32_0 {0.f};
float c1_f32_1 {0.f};
@@ -407,7 +407,7 @@ struct TestStruct {
float c1_f32_3 {0.f};
// float compressed [-1000; 1000] range
constexpr static float c2_f32_resolution = 0.01;
constexpr static float c2_f32_resolution = 0.01f;
constexpr static MM::ScalarRange2<float> c2_f32_r{-1000.f, 1000.f};
float c2_f32_0 {0.f};
float c2_f32_1 {0.f};