mirror of
https://github.com/hedge-dev/UnleashedRecomp.git
synced 2025-04-28 21:37:58 +03:00
Add Metal CMake option
Signed-off-by: Isaac Marovitz <isaacryu@icloud.com>
This commit is contained in:
parent
018f7ee0b4
commit
cf89e03486
2 changed files with 11 additions and 0 deletions
|
@ -4,6 +4,10 @@ if (WIN32)
|
|||
option(UNLEASHED_RECOMP_D3D12 "Add D3D12 support for rendering" ON)
|
||||
endif()
|
||||
|
||||
if (APPLE)
|
||||
option(UNLEASHED_RECOMP_METAL "Add Metal support for rendering" ON)
|
||||
endif()
|
||||
|
||||
if (CMAKE_SYSTEM_NAME MATCHES "Linux")
|
||||
option(UNLEASHED_RECOMP_FLATPAK "Configure the build for Flatpak compatibility." OFF)
|
||||
endif()
|
||||
|
|
|
@ -785,6 +785,13 @@ static void LoadEmbeddedResources()
|
|||
g_shaderCache = std::make_unique<uint8_t[]>(g_spirvCacheDecompressedSize);
|
||||
ZSTD_decompress(g_shaderCache.get(), g_spirvCacheDecompressedSize, g_compressedSpirvCache, g_spirvCacheCompressedSize);
|
||||
}
|
||||
#ifdef UNLEASHED_RECOMP_METAL
|
||||
else
|
||||
{
|
||||
g_shaderCache = std::make_unique<uint8_t[]>(g_airCacheDecompressedSize);
|
||||
ZSTD_decompress(g_shaderCache.get(), g_airCacheDecompressedSize, g_compressedAirCache, g_airCacheCompressedSize);
|
||||
}
|
||||
#endif
|
||||
#ifdef UNLEASHED_RECOMP_D3D12
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue