mirror of
https://github.com/GPUOpen-LibrariesAndSDKs/VulkanMemoryAllocator.git
synced 2025-05-14 16:58:34 +00:00
Improved documentation chapter "Resource aliasing (overlap)"
This commit is contained in:
parent
dd09767ff6
commit
66afe099f1
2 changed files with 8 additions and 1 deletions
|
@ -18208,6 +18208,12 @@ vkDestroyImage(allocator, img2, nullptr);
|
|||
vkDestroyImage(allocator, img1, nullptr);
|
||||
\endcode
|
||||
|
||||
VMA also provides convenience functions that create a buffer or image and bind it to memory
|
||||
represented by an existing #VmaAllocation:
|
||||
vmaCreateAliasingBuffer(), vmaCreateAliasingBuffer2(),
|
||||
vmaCreateAliasingImage(), vmaCreateAliasingImage2().
|
||||
Versions with "2" offer additional parameter `allocationLocalOffset`.
|
||||
|
||||
Remember that using resources that alias in memory requires proper synchronization.
|
||||
You need to issue a memory barrier to make sure commands that use `img1` and `img2`
|
||||
don't overlap on GPU timeline.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue