2021-05-25 15:49:48 +00:00
|
|
|
cmake_minimum_required(VERSION 3.9)
|
|
|
|
|
|
|
|
project(VulkanMemoryAllocator)
|
|
|
|
|
|
|
|
find_package(Vulkan REQUIRED)
|
2021-07-23 09:53:11 +00:00
|
|
|
include_directories(${Vulkan_INCLUDE_DIR})
|
2021-05-25 15:49:48 +00:00
|
|
|
|
2021-05-31 21:43:54 +00:00
|
|
|
# VulkanMemoryAllocator contains an sample application and VmaReplay which are not build by default
|
|
|
|
option(VMA_BUILD_SAMPLE "Build VulkanMemoryAllocator sample application" OFF)
|
|
|
|
option(VMA_BUILD_SAMPLE_SHADERS "Build VulkanMemoryAllocator sample application's shaders" OFF)
|
|
|
|
option(VMA_BUILD_REPLAY "Build VulkanMemoryAllocator replay application" OFF)
|
2021-05-27 23:43:56 +00:00
|
|
|
|
2021-06-01 22:22:18 +00:00
|
|
|
message(STATUS "VMA_BUILD_SAMPLE = ${VMA_BUILD_SAMPLE}")
|
|
|
|
message(STATUS "VMA_BUILD_SAMPLE_SHADERS = ${VMA_BUILD_SAMPLE_SHADERS}")
|
|
|
|
message(STATUS "VMA_BUILD_REPLAY = ${VMA_BUILD_REPLAY}")
|
|
|
|
|
|
|
|
option(VMA_RECORDING_ENABLED "Enable VMA memory recording for debugging" OFF)
|
|
|
|
option(VMA_USE_STL_CONTAINERS "Use C++ STL containers instead of VMA's containers" OFF)
|
2021-06-02 21:17:35 +00:00
|
|
|
option(VMA_STATIC_VULKAN_FUNCTIONS "Link statically with Vulkan API" OFF)
|
|
|
|
option(VMA_DYNAMIC_VULKAN_FUNCTIONS "Fetch pointers to Vulkan functions internally (no static linking)" ON)
|
2021-06-01 22:22:18 +00:00
|
|
|
option(VMA_DEBUG_ALWAYS_DEDICATED_MEMORY "Every allocation will have its own memory block" OFF)
|
|
|
|
option(VMA_DEBUG_INITIALIZE_ALLOCATIONS "Automatically fill new allocations and destroyed allocations with some bit pattern" OFF)
|
|
|
|
option(VMA_DEBUG_GLOBAL_MUTEX "Enable single mutex protecting all entry calls to the library" OFF)
|
|
|
|
option(VMA_DEBUG_DONT_EXCEED_MAX_MEMORY_ALLOCATION_COUNT "Never exceed VkPhysicalDeviceLimits::maxMemoryAllocationCount and return error" OFF)
|
|
|
|
|
|
|
|
message(STATUS "VMA_RECORDING_ENABLED = ${VMA_RECORDING_ENABLED}")
|
|
|
|
message(STATUS "VMA_USE_STL_CONTAINERS = ${VMA_USE_STL_CONTAINERS}")
|
|
|
|
message(STATUS "VMA_DYNAMIC_VULKAN_FUNCTIONS = ${VMA_DYNAMIC_VULKAN_FUNCTIONS}")
|
|
|
|
message(STATUS "VMA_DEBUG_ALWAYS_DEDICATED_MEMORY = ${VMA_DEBUG_ALWAYS_DEDICATED_MEMORY}")
|
|
|
|
message(STATUS "VMA_DEBUG_INITIALIZE_ALLOCATIONS = ${VMA_DEBUG_INITIALIZE_ALLOCATIONS}")
|
|
|
|
message(STATUS "VMA_DEBUG_GLOBAL_MUTEX = ${VMA_DEBUG_GLOBAL_MUTEX}")
|
|
|
|
message(STATUS "VMA_DEBUG_DONT_EXCEED_MAX_MEMORY_ALLOCATION_COUNT = ${VMA_DEBUG_DONT_EXCEED_MAX_MEMORY_ALLOCATION_COUNT}")
|
|
|
|
|
2021-05-25 15:49:48 +00:00
|
|
|
add_subdirectory(src)
|