diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..9578f6e --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,61 @@ +name: Build Code + +on: + push: + pull_request: + types: [opened] + +env: + VMA_VULKAN_VERSION: "1.3.283.0" + VMA_VULKAN_SDK_PATH: "$GITHUB_WORKSPACE/../vulkan_sdk/" + +jobs: + windows: + name: ${{ matrix.config.name }} + runs-on: windows-latest + strategy: + fail-fast: false + matrix: + config: + - { + name: "Windows MSVC (Debug)", + compiler: "msvc", + cc: "cl", cxx: "cl", + cmake_configure_options: '-G "Visual Studio 17 2022" -A x64', + build_type: "Debug", + } + - { + name: "Windows MSVC (Release)", + compiler: "msvc", + cc: "cl", cxx: "cl", + cmake_configure_options: '-G "Visual Studio 17 2022" -A x64', + build_type: "Release", + } + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Install Vulkan SDK + shell: pwsh + run: | + curl -LS -o vulkansdk.exe https://sdk.lunarg.com/sdk/download/${{ env.VMA_VULKAN_VERSION }}/windows/VulkanSDK-${{ env.VMA_VULKAN_VERSION }}-Installer.exe + 7z x vulkansdk.exe -o"${{ env.VMA_VULKAN_SDK_PATH }}" + + - name: Configure CMake + shell: pwsh + run: | + $env:CC="${{ matrix.config.cc }}" + $env:CXX="${{ matrix.config.cxx }}" + $env:Path += ";${{ env.VMA_VULKAN_SDK_PATH }}\;${{ env.VMA_VULKAN_SDK_PATH }}\Bin\" + $env:VULKAN_SDK="${{ env.VMA_VULKAN_SDK_PATH }}" + cmake . ` + -Bbuild ` + -DCMAKE_BUILD_TYPE=${{ matrix.config.build_type }} ` + -DVMA_BUILD_SAMPLES=ON ` + ${{ matrix.config.cmake_configure_options }} + + - name: Build + shell: pwsh + run: | + cmake --build build --config ${{ matrix.config.build_type }} diff --git a/CHANGELOG.md b/CHANGELOG.md index 5bd6460..7eacf38 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,23 @@ +# 3.2.1 (2025-02-05) + +Changes: + +- Fixed an assert in `vmaCreateAllocator` function incorrectly failing when Vulkan version 1.4 is used (#457). +- Fix for importing function `vkGetPhysicalDeviceMemoryProperties2` / `vkGetPhysicalDeviceMemoryProperties2KHR` when `VMA_DYNAMIC_VULKAN_FUNCTIONS` macro is enabled (#410). +- Other minor fixes and improvements... + +# 3.2.0 (2024-12-30) + +Additions to the library API: + +- Added support for Vulkan 1.4. +- Added support for VK_KHR_external_memory_win32 extension - `VMA_ALLOCATOR_CREATE_KHR_EXTERNAL_MEMORY_WIN32_BIT` flag, `vmaGetMemoryWin32Handle` function, and a whole new documentation chapter about it (#442). + +Other changes: + +- Fixed thread safety issue (#451). +- Many other bug fixes and improvements in the library code, documentation, sample app, Cmake script, mostly to improve compatibility with various compilers and GPUs. + # 3.1.0 (2024-05-27) This release gathers fixes and improvements made during many months of continuous development on the main branch, mostly based on issues and pull requests on GitHub. diff --git a/CMakeLists.txt b/CMakeLists.txt index c6a5811..0713825 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,6 +1,28 @@ +# +# Copyright (c) 2017-2025 Advanced Micro Devices, Inc. All rights reserved. +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to deal +# in the Software without restriction, including without limitation the rights +# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +# copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in +# all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +# THE SOFTWARE. +# + cmake_minimum_required(VERSION 3.15...3.26) -project(VMA VERSION 3.1.0 LANGUAGES CXX) +project(VMA VERSION 3.2.1 LANGUAGES CXX) add_library(VulkanMemoryAllocator INTERFACE) add_library(GPUOpen::VulkanMemoryAllocator ALIAS VulkanMemoryAllocator) diff --git a/LICENSE.txt b/LICENSE.txt index b9fff38..a080d9b 100644 --- a/LICENSE.txt +++ b/LICENSE.txt @@ -1,4 +1,4 @@ -Copyright (c) 2017-2024 Advanced Micro Devices, Inc. All rights reserved. +Copyright (c) 2017-2025 Advanced Micro Devices, Inc. All rights reserved. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index 10c4e43..d6fc640 100644 --- a/README.md +++ b/README.md @@ -48,7 +48,7 @@ Additional features: - Support for sparse binding and sparse residency: Convenience functions that allocate or free multiple memory pages at once. - Custom memory pools: Create a pool with desired parameters (e.g. fixed or limited maximum size) and allocate memory out of it. - Linear allocator: Create a pool with linear algorithm and use it for much faster allocations and deallocations in free-at-once, stack, double stack, or ring buffer fashion. -- Support for Vulkan 1.0, 1.1, 1.2, 1.3. +- Support for Vulkan 1.0...1.4. - Support for extensions (and equivalent functionality included in new Vulkan versions): - VK_KHR_dedicated_allocation: Just enable it and it will be used automatically by the library. - VK_KHR_bind_memory2. @@ -156,6 +156,7 @@ See **[Documentation](https://gpuopen-librariesandsdks.github.io/VulkanMemoryAll # Software using this library - **[Blender](https://www.blender.org)** +- **[Qt Project](https://github.com/qt)** - **[Baldur's Gate III](https://www.mobygames.com/game/150689/baldurs-gate-iii/credits/windows/?autoplatform=true)** - **[Cyberpunk 2077](https://www.mobygames.com/game/128136/cyberpunk-2077/credits/windows/?autoplatform=true)** - **[X-Plane](https://x-plane.com/)** diff --git a/bin/Shader.frag.spv b/bin/Shader.frag.spv index 065a803..d47ff39 100644 Binary files a/bin/Shader.frag.spv and b/bin/Shader.frag.spv differ diff --git a/bin/Shader.vert.spv b/bin/Shader.vert.spv index 8a568e7..5629e04 100644 Binary files a/bin/Shader.vert.spv and b/bin/Shader.vert.spv differ diff --git a/bin/VmaSample_Release_vs2022.exe b/bin/VmaSample_Release_vs2022.exe index 7e86cd2..2140219 100644 Binary files a/bin/VmaSample_Release_vs2022.exe and b/bin/VmaSample_Release_vs2022.exe differ diff --git a/docs/html/allocation_annotation.html b/docs/html/allocation_annotation.html index da16467..dc19902 100644 --- a/docs/html/allocation_annotation.html +++ b/docs/html/allocation_annotation.html @@ -3,7 +3,7 @@ - + Vulkan Memory Allocator: Allocation names and user data @@ -33,7 +33,7 @@ - +