C Specification
To build acceleration structures call:
void vkCmdBuildAccelerationStructureKHR(
VkCommandBuffer commandBuffer,
uint32_t infoCount,
const VkAccelerationStructureBuildGeometryInfoKHR* pInfos,
const VkAccelerationStructureBuildOffsetInfoKHR* const* ppOffsetInfos);
Parameters
-
commandBuffer
is the command buffer into which the command will be recorded. -
infoCount
is the number of acceleration structures to build. It specifies the number of thepInfos
structures andppOffsetInfos
pointers that must be provided. -
pInfos
is an array ofinfoCount
VkAccelerationStructureBuildGeometryInfoKHR structures defining the geometry used to build each acceleration structure. -
ppOffsetInfos
is an array ofinfoCount
pointers to arrays of VkAccelerationStructureBuildOffsetInfoKHR structures. EachppOffsetInfos
[i] is an array ofpInfos
[i]→geometryCount
VkAccelerationStructureBuildOffsetInfoKHR structures defining dynamic offsets to the addresses where geometry data is stored, as defined bypInfos
[i].
Description
The vkCmdBuildAccelerationStructureKHR
command provides the ability to
initiate multiple acceleration structures builds, however there is no
ordering or synchronization implied between any of the individual
acceleration structure builds.
Note
This means that an application cannot build a top-level acceleration structure in the same vkCmdBuildAccelerationStructureKHR call as the associated bottom-level or instance acceleration structures are being built. There also cannot be any memory aliasing between any acceleration structure memories or scratch memories being used by any of the builds. |
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.
Copyright
Copyright (c) 2014-2020 Khronos Group. This work is licensed under a Creative Commons Attribution 4.0 International License.