Modulevulkan-3.27GHC2021
Vulkan.Extensions.VK_NV_displacement_micromap
Name
VK_NV_displacement_micromap - device extension
VK_NV_displacement_micromap
- Name String
VK_NV_displacement_micromap
- Extension Type
Device extension
- Registered Extension Number
398
- Revision
2
- Ratification Status
Not ratified
- Extension and Version Dependencies
__This is a provisional extension and must be used with caution. See the description of provisional header files for enablement and stability details.__
- Deprecation State
Deprecated by VK_NV_cluster_acceleration_structure extension
- Contact
Other Extension Metadata
- Last Modified Date
2023-03-17
- Interactions and External Dependencies
TBD
- Contributors
Christoph Kubisch, NVIDIA
Eric Werness, NVIDIA
Description
Ray tracing can very efficiently render from geometry which has very fine detail, but when using only a basic triangle representation, memory consumption can be an issue. This extension adds the ability to add a displacement map to add more detail to triangles in an acceleration structure with an efficient in-memory format. The format is externally visible to allow the application to compress its internal geometry representations into the compressed format ahead of time. This format adds displacements along a defined vector to subtriangle vertices which are subdivided from the main triangles.
This extension provides:
a new MicromapTypeEXT format for the displacement micromap,
a structure to extend AccelerationStructureGeometryTrianglesDataKHR to attach a displacement micromap to the geometry of the acceleration structure,
enums extending BuildAccelerationStructureFlagBitsKHR to allow for updates.
New Structures
Extending PhysicalDeviceFeatures2, DeviceCreateInfo:
Extending PhysicalDeviceProperties2:
New Enums
New Enum Constants
Extending BuildAccelerationStructureFlagBitsKHR:
Extending MicromapTypeEXT:
Extending PipelineCreateFlagBits:
Extending StructureType:
Issues
What is the status of this extension?
Deprecated. The VK_NV_cluster_acceleration_structure extension is not a one-to-one replacement for this extension but enables similar performance improvements for high-tessellation geometry and is considered the preferred direction to improve high-tessellation geometry performance.
Version History
Revision 1, 2023-03-17 (Eric Werness)
Initial public revision
Revision 2, 2023-07-07 (Eric Werness)
Add shader support for decode intrinsics
See Also
No cross-references are available
Document Notes
For more information, see the Vulkan Specification.
This page is a generated document. Fixes and changes should be made to the generator scripts, not directly.
- 12 types
- Packagevulkan-3.27
- Exports32
- LanguageGHC2021
- LicenceBSD-3-Clause
- SourceVK_NV_displacement_micromap.hs
VkPhysicalDeviceDisplacementMicromapFeaturesNV - Structure describing the ray tracing displacement micromap features that can be supported by an implementation
Members
This structure describes the following feature:
Description
If the PhysicalDeviceDisplacementMicromapFeaturesNV structure is
included in the pNext chain of the
PhysicalDeviceFeatures2
structure passed to
getPhysicalDeviceFeatures2,
it is filled in to indicate whether each corresponding feature is
supported. If the application wishes to use a
Device with any features described by
PhysicalDeviceDisplacementMicromapFeaturesNV, it must add an
instance of the structure, with the desired feature members set to
TRUE, to the pNext chain of
DeviceCreateInfo when creating the
Device.
Structure Chaining
See Also
Constructors
PhysicalDeviceDisplacementMicromapFeaturesNVdisplacementMicromap :: BooldisplacementMicromapindicates whether the implementation supports the displacement micromap feature.
Instances6Eq, Show, Storable, FromCStruct, ToCStruct, Zero
Eq PhysicalDeviceDisplacementMicromapFeaturesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapShow PhysicalDeviceDisplacementMicromapFeaturesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapStorable PhysicalDeviceDisplacementMicromapFeaturesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapFromCStruct PhysicalDeviceDisplacementMicromapFeaturesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapToCStruct PhysicalDeviceDisplacementMicromapFeaturesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapZero PhysicalDeviceDisplacementMicromapFeaturesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromap
VkPhysicalDeviceDisplacementMicromapPropertiesNV - Structure describing the displacement micromap properties of a physical device
Description
If the PhysicalDeviceDisplacementMicromapPropertiesNV structure is
included in the pNext chain of the
PhysicalDeviceProperties2
structure passed to
getPhysicalDeviceProperties2,
it is filled in with each corresponding implementation-dependent
property.
Structure Chaining
See Also
Constructors
PhysicalDeviceDisplacementMicromapPropertiesNVmaxDisplacementMicromapSubdivisionLevel :: Word32maxDisplacementMicromapSubdivisionLevelis the maximum allowedsubdivisionLevelfor displacement micromaps.
Instances6Eq, Show, Storable, FromCStruct, ToCStruct, Zero
Eq PhysicalDeviceDisplacementMicromapPropertiesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapShow PhysicalDeviceDisplacementMicromapPropertiesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapStorable PhysicalDeviceDisplacementMicromapPropertiesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapFromCStruct PhysicalDeviceDisplacementMicromapPropertiesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapToCStruct PhysicalDeviceDisplacementMicromapPropertiesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapZero PhysicalDeviceDisplacementMicromapPropertiesNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromap
VkAccelerationStructureTrianglesDisplacementMicromapNV - Structure specifying a displacement micromap in a bottom-level acceleration structure
Description
If AccelerationStructureTrianglesDisplacementMicromapNV is included in
the pNext chain of a
AccelerationStructureGeometryTrianglesDataKHR
structure, that geometry will reference that micromap.
For each triangle in the geometry, the acceleration structure build
fetches an index from indexBuffer using indexType and indexStride.
That triangle uses the displacement micromap information from micromap
at that index plus baseTriangle.
Only one of pUsageCounts or ppUsageCounts can be a valid pointer,
the other must be NULL. The elements of the non-NULL array
describe the total count used to build this geometry. For a given
format and subdivisionLevel the number of triangles in this geometry
matching those values after indirection must be equal to the sum of
matching count provided.
Valid Usage
displacementBiasAndScaleFormatmust not be FORMAT_UNDEFINED
displacementVectorFormatmust not be FORMAT_UNDEFINEDOnly one of
pUsageCountsorppUsageCountscan be a valid pointer, the other must beNULL
Valid Usage (Implicit)
displacementBiasAndScaleFormatmust be a valid Format valuedisplacementVectorFormatmust be a valid Format valueindexTypemust be a valid IndexType valueIf
usageCountsCountis not0, andpUsageCountsis notNULL,pUsageCountsmust be a valid pointer to an array ofusageCountsCountMicromapUsageEXT structuresIf
usageCountsCountis not0, andppUsageCountsis notNULL,ppUsageCountsmust be a valid pointer to an array ofusageCountsCountvalid pointers to MicromapUsageEXT structuresIf
micromapis not NULL_HANDLE,micromapmust be a valid MicromapEXT handle
Structure Chaining
See Also
VK_NV_displacement_micromap, DeviceOrHostAddressConstKHR, DeviceSize, Format, IndexType, MicromapEXT, MicromapUsageEXT, StructureType
Constructors
AccelerationStructureTrianglesDisplacementMicromapNVdisplacementBiasAndScaleFormat :: FormatdisplacementBiasAndScaleFormatis the format of displacement bias and scale used in this displacement micromap reference.displacementVectorFormat :: FormatdisplacementVectorFormatis the format of displacement vector used in this displacement micromap reference.displacementBiasAndScaleBuffer :: DeviceOrHostAddressConstKHRdisplacementBiasAndScaleBufferis the address containing the bias and scale.displacementBiasAndScaleStride :: DeviceSizedisplacementBiasAndScaleStrideis the byte stride between bias and scale values.displacementVectorBuffer :: DeviceOrHostAddressConstKHRdisplacementVectorBufferis the address containing the displacement vector values.displacementVectorStride :: DeviceSizedisplacementVectorStrideis the byte stride between displacement vector values.displacedMicromapPrimitiveFlags :: DeviceOrHostAddressConstKHRdisplacedMicromapPrimitiveFlagsis the address containing the primitive flags.displacedMicromapPrimitiveFlagsStride :: DeviceSizedisplacedMicromapPrimitiveFlagsStrideis the byte stride between primitive flag values.indexType :: IndexTypeindexTypeis the type of triangle indices used when indexing this micromap.indexBuffer :: DeviceOrHostAddressConstKHRindexBufferis a device or host address of memory containing the triangle indices. WhenindexTypeis INDEX_TYPE_NONE_KHR it must beNULL.indexStride :: DeviceSizeindexStrideis the byte stride between triangle indices.baseTriangle :: Word32baseTriangleis the base value added to the non-negative triangle indices.usageCounts :: Vector MicromapUsageEXTpUsageCountsis a pointer to an array of MicromapUsageEXT structures.micromap :: MicromapEXTmicromapis the handle to the micromap object to include in this geometry.
Instances3Show, ToCStruct, Zero
Show AccelerationStructureTrianglesDisplacementMicromapNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapToCStruct AccelerationStructureTrianglesDisplacementMicromapNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapZero AccelerationStructureTrianglesDisplacementMicromapNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromap
VkDisplacementMicromapFormatNV - Format enum for displacement micromaps
Description
DISPLACEMENT_MICROMAP_FORMAT_64_TRIANGLES_64_BYTES_NV specifies that the given micromap format encodes 64 micro-triangles worth of displacements in 64 bytes as described in Displacement Micromap Encoding.
DISPLACEMENT_MICROMAP_FORMAT_256_TRIANGLES_128_BYTES_NV specifies that the given micromap format encodes 256 micro-triangles worth of displacements in 128 bytes as described in Displacement Micromap Encoding.
DISPLACEMENT_MICROMAP_FORMAT_1024_TRIANGLES_128_BYTES_NV specifies that the given micromap format encodes 1024 micro-triangles worth of displacements in 128 bytes as described in Displacement Micromap Encoding.
For compactness, these values are stored as 16-bit in some structures.
See Also
Constructors
Instances6Eq, Ord, Read, Show, Storable, Zero
Eq DisplacementMicromapFormatNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapOrd DisplacementMicromapFormatNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapRead DisplacementMicromapFormatNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapShow DisplacementMicromapFormatNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapStorable DisplacementMicromapFormatNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromapZero DisplacementMicromapFormatNVDefined in vulkan-3.27 · Vulkan.Extensions.VK_NV_displacement_micromap
VkMicromapEXT - Opaque handle to a micromap object
See Also
VK_DEFINE_NON_DISPATCHABLE_HANDLE, VK_EXT_opacity_micromap, AccelerationStructureTrianglesDisplacementMicromapNV, AccelerationStructureTrianglesOpacityMicromapEXT, CopyMemoryToMicromapInfoEXT, CopyMicromapInfoEXT, CopyMicromapToMemoryInfoEXT, MicromapBuildInfoEXT, cmdWriteMicromapsPropertiesEXT, createMicromapEXT, destroyMicromapEXT, writeMicromapsPropertiesEXT
Constructors
Instances7Eq, Ord, Show, Storable, HasObjectType, IsHandle, …
Eq MicromapEXTDefined in vulkan-3.27 · Vulkan.Extensions.HandlesOrd MicromapEXTDefined in vulkan-3.27 · Vulkan.Extensions.HandlesShow MicromapEXTDefined in vulkan-3.27 · Vulkan.Extensions.HandlesStorable MicromapEXTDefined in vulkan-3.27 · Vulkan.Extensions.HandlesHasObjectType MicromapEXTDefined in vulkan-3.27 · Vulkan.Extensions.HandlesIsHandle MicromapEXTDefined in vulkan-3.27 · Vulkan.Extensions.HandlesZero MicromapEXTDefined in vulkan-3.27 · Vulkan.Extensions.Handles
VkMicromapUsageEXT - Structure specifying the usage information used to build a micromap
Description
The format is interpreted based on the type of the micromap using
it.
See Also
VK_EXT_opacity_micromap, AccelerationStructureTrianglesDisplacementMicromapNV, AccelerationStructureTrianglesOpacityMicromapEXT, MicromapBuildInfoEXT
Constructors
Instances6Eq, Show, Storable, FromCStruct, ToCStruct, Zero
Eq MicromapUsageEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromapShow MicromapUsageEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromapStorable MicromapUsageEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromapFromCStruct MicromapUsageEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromapToCStruct MicromapUsageEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromapZero MicromapUsageEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromap
Constructors
Instances3Show, ToCStruct, Zero
Show DeviceOrHostAddressConstKHRDefined in vulkan-3.27 · Vulkan.Extensions.VK_KHR_acceleration_structureToCStruct DeviceOrHostAddressConstKHRDefined in vulkan-3.27 · Vulkan.Extensions.VK_KHR_acceleration_structureZero DeviceOrHostAddressConstKHRDefined in vulkan-3.27 · Vulkan.Extensions.VK_KHR_acceleration_structure
VkBuildAccelerationStructureFlagBitsKHR - Bitmask specifying additional parameters for acceleration structure builds
Description
BUILD_ACCELERATION_STRUCTURE_ALLOW_UPDATE_BIT_KHR specifies that the specified acceleration structure can be updated with a
modeof BUILD_ACCELERATION_STRUCTURE_MODE_UPDATE_KHR in AccelerationStructureBuildGeometryInfoKHR or anupdateof TRUE in cmdBuildAccelerationStructureNV . For sphere and LSS primitives, only positions and radii may be updated, the provided index buffers and flags must remain unchanged from the initial build.
BUILD_ACCELERATION_STRUCTURE_ALLOW_COMPACTION_BIT_KHR specifies that the specified acceleration structure can act as the source for a copy acceleration structure command with
modeof COPY_ACCELERATION_STRUCTURE_MODE_COMPACT_KHR to produce a compacted acceleration structure.BUILD_ACCELERATION_STRUCTURE_PREFER_FAST_TRACE_BIT_KHR specifies that the given acceleration structure build should prioritize trace performance over build time.
BUILD_ACCELERATION_STRUCTURE_PREFER_FAST_BUILD_BIT_KHR specifies that the given acceleration structure build should prioritize build time over trace performance.
BUILD_ACCELERATION_STRUCTURE_LOW_MEMORY_BIT_KHR specifies that this acceleration structure should minimize the size of the scratch memory and the final result acceleration structure, potentially at the expense of build time or trace performance.
BUILD_ACCELERATION_STRUCTURE_ALLOW_OPACITY_MICROMAP_UPDATE_BIT_KHR specifies that the opacity micromaps associated with the specified acceleration structure may change with an acceleration structure update.
BUILD_ACCELERATION_STRUCTURE_ALLOW_OPACITY_MICROMAP_DATA_UPDATE_BIT_EXT specifies that the data of the opacity micromaps associated with the specified acceleration structure may change with an acceleration structure update.
BUILD_ACCELERATION_STRUCTURE_ALLOW_DISABLE_OPACITY_MICROMAPS_BIT_KHR specifies that the specified acceleration structure may be referenced in an instance with GEOMETRY_INSTANCE_DISABLE_OPACITY_MICROMAPS_BIT_KHR set.
VK_BUILD_ACCELERATION_STRUCTURE_ALLOW_CLUSTER_OPACITY_MICROMAPS_BIT_NV specifies that opacity micromaps may be associated with the given cluster acceleration structure.
BUILD_ACCELERATION_STRUCTURE_ALLOW_DATA_ACCESS_BIT_KHR specifies that the specified acceleration structure can be used when fetching the vertex and radius positions of a hit LSS or sphere primitive, or vertex positions of a hit triangle.
BUILD_ACCELERATION_STRUCTURE_MICROMAP_LOSSY_BIT_KHR specifies that micromaps can be compressed with a lossy encoding as described in Ray Opacity Micromap, which may support additional subdivision levels.
BUILD_ACCELERATION_STRUCTURE_ALLOW_DISPLACEMENT_MICROMAP_UPDATE_BIT_NV specifies that the displacement micromaps associated with the specified acceleration structure may change with an acceleration structure update.
BUILD_ACCELERATION_STRUCTURE_ALLOW_UPDATE_BIT_KHR and BUILD_ACCELERATION_STRUCTURE_ALLOW_COMPACTION_BIT_KHR may take more time and memory than a normal build, and so should only be used when those features are needed.
BUILD_ACCELERATION_STRUCTURE_ALLOW_UPDATE_BIT_KHR and
BUILD_ACCELERATION_STRUCTURE_ALLOW_COMPACTION_BIT_KHR are allowed to
be used together. In that case, the result of the compaction copy is
used as the source of a build with mode of
BUILD_ACCELERATION_STRUCTURE_MODE_UPDATE_KHR to perform the compacted
update.
See Also
VK_KHR_acceleration_structure, VK_NV_ray_tracing, BuildAccelerationStructureFlagsKHR
Constructors
Instances8Eq, Ord, Read, Show, Bits, FiniteBits, …
Eq BuildAccelerationStructureFlagBitsKHRDefined in vulkan-3.27 · Vulkan.Extensions.VK_KHR_acceleration_structureOrd BuildAccelerationStructureFlagBitsKHRDefined in vulkan-3.27 · Vulkan.Extensions.VK_KHR_acceleration_structureRead BuildAccelerationStructureFlagBitsKHRDefined in vulkan-3.27 · Vulkan.Extensions.VK_KHR_acceleration_structureShow BuildAccelerationStructureFlagBitsKHRDefined in vulkan-3.27 · Vulkan.Extensions.VK_KHR_acceleration_structureBits BuildAccelerationStructureFlagBitsKHRDefined in vulkan-3.27 · Vulkan.Extensions.VK_KHR_acceleration_structureFiniteBits BuildAccelerationStructureFlagBitsKHRDefined in vulkan-3.27 · Vulkan.Extensions.VK_KHR_acceleration_structureStorable BuildAccelerationStructureFlagBitsKHRDefined in vulkan-3.27 · Vulkan.Extensions.VK_KHR_acceleration_structureZero BuildAccelerationStructureFlagBitsKHRDefined in vulkan-3.27 · Vulkan.Extensions.VK_KHR_acceleration_structure
VkMicromapTypeEXT - Type of micromap
Description
MICROMAP_TYPE_OPACITY_MICROMAP_EXT is a micromap containing data to control the opacity of a triangle.
MICROMAP_TYPE_DISPLACEMENT_MICROMAP_NV is a micromap containing data to control the displacement of subtriangles within a triangle.
See Also
VK_EXT_opacity_micromap, MicromapBuildInfoEXT, MicromapCreateInfoEXT
Constructors
Instances6Eq, Ord, Read, Show, Storable, Zero
Eq MicromapTypeEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromapOrd MicromapTypeEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromapRead MicromapTypeEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromapShow MicromapTypeEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromapStorable MicromapTypeEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromapZero MicromapTypeEXTDefined in vulkan-3.27 · Vulkan.Extensions.VK_EXT_opacity_micromap