From 93e86db66b3e43944bb493a99ecbdd6cd78676ff Mon Sep 17 00:00:00 2001 From: Auburn Date: Sun, 28 Jan 2024 10:00:26 +0000 Subject: [PATCH] Fix domain warp fractal gain slider not functioning in UI, updated Emscripten --- WebPreviewApp/build.ps1 | 10 +++++----- WebPreviewApp/main.cpp | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/WebPreviewApp/build.ps1 b/WebPreviewApp/build.ps1 index 6f5a158..9395ac1 100644 --- a/WebPreviewApp/build.ps1 +++ b/WebPreviewApp/build.ps1 @@ -1,15 +1,15 @@ $scriptPath = $PSScriptRoot -$emsdkVer = "3.1.44" -$emsdkPath = Join-Path -Path $PSScriptRoot -ChildPath "emsdk" +$emsdkVer = "3.1.52" +$emsdkPath = Join-Path -Path $PSScriptRoot -ChildPath "emsdk" | Join-Path -ChildPath $emsdkVer if (Test-Path -Path $emsdkPath -PathType Container) { Write-Host "Found existing emsdk" - ./emsdk/emsdk_env.ps1 + & "$emsdkPath\emsdk_env.ps1" } else { Write-Host "Building emsdk" git clone --branch $emsdkVer "https://github.com/emscripten-core/emsdk.git" $emsdkPath - ./emsdk/emsdk.ps1 install $emsdkVer - ./emsdk/emsdk.ps1 activate $emsdkVer + & "$emsdkPath\emsdk.ps1" install $emsdkVer + & "$emsdkPath\emsdk.ps1" activate $emsdkVer } emcc --version diff --git a/WebPreviewApp/main.cpp b/WebPreviewApp/main.cpp index d777f60..cff63d8 100644 --- a/WebPreviewApp/main.cpp +++ b/WebPreviewApp/main.cpp @@ -243,7 +243,7 @@ class FastNoiseLitePreviewApp : public ImGui_Application fnlWarp.SetFractalLacunarity(fnlDomainWarpFractalLacunarity); texUpdate = true; } - if (ImGui::DragFloat("Gain", &fnlFractalGain, 0.01f)) + if (ImGui::DragFloat("Gain", &fnlDomainWarpFractalGain, 0.01f)) { fnlWarp.SetFractalGain(fnlDomainWarpFractalGain); texUpdate = true;