diff options
| author | ItsNotRexed <300290919+ItsNotRexed@users.noreply.github.com> | 2026-11-23 17:43:36 -0500 |
|---|---|---|
| committer | ItsNotRexed <300290919+ItsNotRexed@users.noreply.github.com> | 2026-11-23 17:43:36 -0500 |
| commit | be4a51f5d415b3101b5ef9776107ec1dac8b2c17 (patch) | |
| tree | 0d565c8772a4ff7c8f0338a2b3292b501dc06291 /runtime/src/main.cpp | |
| parent | 3faeaf2ca68b4459f6f922244e7ef2ef2ab680dc (diff) | |
| parent | f57ed9da22d9bd258db541e4537006727bc872ad (diff) | |
Merge remote-tracking branch 'origin/pr/8964'
# Conflicts:
# runtime/shims/d3d12_vulkan_device.cpp
Diffstat (limited to 'runtime/src/main.cpp')
| -rw-r--r-- | runtime/src/main.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/runtime/src/main.cpp b/runtime/src/main.cpp index 491873fd1..fbb4b3043 100644 --- a/runtime/src/main.cpp +++ b/runtime/src/main.cpp | |||
| @@ -120,6 +120,15 @@ int wmain(int argc, wchar_t** argv) { | |||
| 120 | }; | 120 | }; |
| 121 | game_dir = game_dir.empty() ? absolute_or_same(image).parent_path() : absolute_or_same(game_dir); | 121 | game_dir = game_dir.empty() ? absolute_or_same(image).parent_path() : absolute_or_same(game_dir); |
| 122 | if (!overlay_dir.empty()) overlay_dir = absolute_or_same(overlay_dir); | 122 | if (!overlay_dir.empty()) overlay_dir = absolute_or_same(overlay_dir); |
| 123 | // LEONIDA_SHADERS too: the D3D12 device reads it at the title's first pipeline state, after it may have moved. | ||
| 124 | if (const DWORD size = GetEnvironmentVariableW(L"LEONIDA_SHADERS", nullptr, 0)) { | ||
| 125 | std::wstring shaders(size, L'\0'); | ||
| 126 | const DWORD n = GetEnvironmentVariableW(L"LEONIDA_SHADERS", shaders.data(), size); | ||
| 127 | if (n && n < size) { | ||
| 128 | shaders.resize(n); | ||
| 129 | SetEnvironmentVariableW(L"LEONIDA_SHADERS", absolute_or_same(shaders).c_str()); | ||
| 130 | } | ||
| 131 | } | ||
| 123 | // An image without relocations whose range this process already uses (arm64 Wine on macOS) runs in a new | 132 | // An image without relocations whose range this process already uses (arm64 Wine on macOS) runs in a new |
| 124 | // process that has the range reserved from the start (base_reservation.h); that process does not do this again. | 133 | // process that has the range reserved from the start (base_reservation.h); that process does not do this again. |
| 125 | if (!rt::base_reservation::inherited()) | 134 | if (!rt::base_reservation::inherited()) |