C Specification

The VkAccelerationStructureInfoNV structure is defined as:

// Provided by VK_NV_ray_tracing
typedef struct VkAccelerationStructureInfoNV {
    VkStructureType                        sType;
    const void*                            pNext;
    VkAccelerationStructureTypeNV          type;
    VkBuildAccelerationStructureFlagsNV    flags;
    uint32_t                               instanceCount;
    uint32_t                               geometryCount;
    const VkGeometryNV*                    pGeometries;
} VkAccelerationStructureInfoNV;

Members

  • sType is a VkStructureType value identifying this structure.

  • pNext is NULL or a pointer to a structure extending this structure.

  • type is a VkAccelerationStructureTypeNV value specifying the type of acceleration structure that will be created.

  • flags is a bitmask of VkBuildAccelerationStructureFlagBitsNV specifying additional parameters of the acceleration structure.

  • instanceCount specifies the number of instances that will be in the new acceleration structure.

  • geometryCount specifies the number of geometries that will be in the new acceleration structure.

  • pGeometries is a pointer to an array of geometryCount VkGeometryNV structures containing the scene data being passed into the acceleration structure.

Description

VkAccelerationStructureInfoNV contains information that is used both for acceleration structure creation with vkCreateAccelerationStructureNV and in combination with the actual geometric data to build the acceleration structure with vkCmdBuildAccelerationStructureNV.

Valid Usage
  • VUID-VkAccelerationStructureInfoNV-geometryCount-02422
    geometryCount must be less than or equal to VkPhysicalDeviceRayTracingPropertiesNV::maxGeometryCount

  • VUID-VkAccelerationStructureInfoNV-instanceCount-02423
    instanceCount must be less than or equal to VkPhysicalDeviceRayTracingPropertiesNV::maxInstanceCount

  • VUID-VkAccelerationStructureInfoNV-maxTriangleCount-02424
    The total number of triangles in all geometries must be less than or equal to VkPhysicalDeviceRayTracingPropertiesNV::maxTriangleCount

  • VUID-VkAccelerationStructureInfoNV-type-02425
    If type is VK_ACCELERATION_STRUCTURE_TYPE_TOP_LEVEL_NV then geometryCount must be 0

  • VUID-VkAccelerationStructureInfoNV-type-02426
    If type is VK_ACCELERATION_STRUCTURE_TYPE_BOTTOM_LEVEL_NV then instanceCount must be 0

  • VUID-VkAccelerationStructureInfoNV-type-02786
    If type is VK_ACCELERATION_STRUCTURE_TYPE_BOTTOM_LEVEL_NV then the geometryType member of each geometry in pGeometries must be the same

  • VUID-VkAccelerationStructureInfoNV-type-04623
    type must not be VK_ACCELERATION_STRUCTURE_TYPE_GENERIC_KHR

  • VUID-VkAccelerationStructureInfoNV-flags-02592
    If flags has the VK_BUILD_ACCELERATION_STRUCTURE_PREFER_FAST_TRACE_BIT_NV bit set, then it must not have the VK_BUILD_ACCELERATION_STRUCTURE_PREFER_FAST_BUILD_BIT_NV bit set

  • VUID-VkAccelerationStructureInfoNV-scratch-02781
    scratch must have been created with VK_BUFFER_USAGE_RAY_TRACING_BIT_NV usage flag

  • VUID-VkAccelerationStructureInfoNV-instanceData-02782
    If instanceData is not VK_NULL_HANDLE, instanceData must have been created with VK_BUFFER_USAGE_RAY_TRACING_BIT_NV usage flag

Valid Usage (Implicit)
  • VUID-VkAccelerationStructureInfoNV-sType-sType
    sType must be VK_STRUCTURE_TYPE_ACCELERATION_STRUCTURE_INFO_NV

  • VUID-VkAccelerationStructureInfoNV-pNext-pNext
    pNext must be NULL

  • VUID-VkAccelerationStructureInfoNV-type-parameter
    type must be a valid VkAccelerationStructureTypeNV value

  • VUID-VkAccelerationStructureInfoNV-flags-parameter
    flags must be a valid combination of VkBuildAccelerationStructureFlagBitsNV values

  • VUID-VkAccelerationStructureInfoNV-pGeometries-parameter
    If geometryCount is not 0, pGeometries must be a valid pointer to an array of geometryCount valid VkGeometryNV structures

See Also

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 2014-2024 The Khronos Group Inc.

SPDX-License-Identifier: CC-BY-4.0