C Specification
To copy a micromap to device memory call:
// Provided by VK_EXT_opacity_micromap
void vkCmdCopyMicromapToMemoryEXT(
VkCommandBuffer commandBuffer,
const VkCopyMicromapToMemoryInfoEXT* pInfo);
Parameters
-
commandBuffer
is the command buffer into which the command will be recorded. -
pInfo
is an a pointer to a VkCopyMicromapToMemoryInfoEXT structure defining the copy operation.
Description
Accesses to pInfo->src
must be synchronized with the VK_PIPELINE_STAGE_2_MICROMAP_BUILD_BIT_EXT
pipeline stage and an
access type of
VK_ACCESS_2_MICROMAP_READ_BIT_EXT
.
Accesses to the buffer indicated by pInfo->dst.deviceAddress
must be
synchronized with the VK_PIPELINE_STAGE_2_MICROMAP_BUILD_BIT_EXT
pipeline stage and an access type of VK_ACCESS_TRANSFER_WRITE_BIT
.
This command produces the same results as vkCopyMicromapToMemoryEXT, but writes its result to a device address, and is executed on the device rather than the host. The output may not necessarily be bit-for-bit identical, but it can be equally used by either vkCmdCopyMemoryToMicromapEXT or vkCopyMemoryToMicromapEXT.
The defined header structure for the serialized data consists of:
-
VK_UUID_SIZE
bytes of data matchingVkPhysicalDeviceIDProperties
::driverUUID
-
VK_UUID_SIZE
bytes of data identifying the compatibility for comparison using vkGetDeviceMicromapCompatibilityEXT The serialized data is written to the buffer (or read from the buffer) according to the host endianness.
Document Notes
For more information, see the Vulkan Specification
This page is extracted from the Vulkan Specification. Fixes and changes should be made to the Specification, not directly.