Vulkan Ray Tracing Launched


Vulkan Ray Tracing Launched

Yesterday, the Khronos Group announced the public release of provisional Vulkan Ray Tracing extensions.

Beaverton, OR – March 17, 2020 – 6:00 AM PT – Today, The Khronos® Group, an open consortium of industry-leading companies creating advanced interoperability standards, announces the ratification and public release of the Vulkan® Ray Tracing provisional extensions, creating the industry’s first open, cross-vendor, cross-platform standard for ray tracing acceleration. Primarily focused on meeting desktop market demand for both real-time and offline rendering, the release of Vulkan Ray Tracing as provisional extensions enables the developer community to provide feedback before the specifications are finalized. Comments and feedback will be collected through the Vulkan GitHub Issues Tracker and Khronos Developer Slack. Developers are also encouraged to share comments with their preferred hardware vendors. The specifications are available today on the Vulkan Registry.

Ray tracing is a rendering technique that realistically simulates how light rays intersect and interact with scene geometry, materials, and light sources to generate photorealistic imagery. It is widely used for film and other production rendering and is beginning to be practical for real-time applications and games. Vulkan Ray Tracing seamlessly integrates a coherent ray tracing framework into the Vulkan API, enabling a flexible merging of rasterization and ray tracing acceleration. Vulkan Ray Tracing is designed to be hardware agnostic and so can be accelerated on both existing GPU compute and dedicated ray tracing cores if available.

“There has been strong developer demand for a truly cross-platform ray tracing acceleration API and now Vulkan Ray Tracing is here to meet that industry need,” said Daniel Koch, senior graphics system software engineer at NVIDIA and Vulkan Ray Tracing task sub group chair at Khronos. “The overall architecture of Vulkan Ray Tracing will be familiar to users of existing proprietary ray tracing APIs, which enables straightforward porting of existing ray traced content, but this framework also introduces new functionality and implementation flexibility.”

Vulkan Ray Tracing consists of a number of Vulkan, SPIR-V, and GLSL extensions, some of which are optional. The primary VK_KHR_ray_tracing extension provides support for acceleration structure building and management, ray tracing shader stages and pipelines, and ray query intrinsics for all shader stages. VK_KHR_pipeline_library provides the ability to provide a set of shaders which can be efficiently linked into ray tracing pipelines. VK_KHR_deferred_host_operations enables intensive driver operations, including ray tracing pipeline compilation or CPU-based acceleration structure construction to be offloaded to application-managed CPU thread pools.

Vulkan Ray Tracing shaders are SPIR-V binaries which use two new extensions. The SPV_KHR_ray_tracing SPIR-V extension adds support for ray tracing shader stages and instructions; SPV_KHR_ray_query adds support for ray query shader instructions. Developers can generate those binaries in GLSL using two new GLSL extensions, GLSL_EXT_ray_tracing and GLSL_EXT_ray_query, which are supported in the open source glslang compiler. Engineers at Khronos member companies, including NVIDIA, have also added support for the SPIR-V extensions to DXC, Microsoft’s open source HLSL compiler, enabling Vulkan Ray Tracing SPIR-V shaders to be authored in HLSL using the syntax defined by Microsoft, with minimal modifications.

Complete press release: Khronos Group Releases Vulkan Ray Tracing

The Vulkan specifications 1.2.135 have been released with new ray tracing extensions.

The ray tracing in Vulkan is essentially based on the following extensions:

  • VK_KHR_ray_tracing: This is the primary Vulkan extension for ray tracing:

    Rasterization has been the dominant method to produce interactive graphics, but increasing performance of graphics hardware has made ray tracing a viable option for interactive rendering. Being able to integrate ray tracing with traditional rasterization makes it
    easier for applications to incrementally add ray traced effects to existing applications or to do hybrid approaches with rasterization for primary visibility and ray tracing for secondary queries.

    To enable ray tracing, this extension adds a few different categories of new functionality:
    * Acceleration structure objects and build commands
    * A new pipeline type with new shader domains
    * An indirection table to link shader groups with acceleration structure items

    Additionally, ray queries are available to other shader types outside of the dedicated ray tracing pipeline. Unlike code:OpTraceRayKHR, ray queries are not able to launch additional shaders, instead returning traversal results to the calling shader.

    This extension adds support for the following SPIR-V extension in Vulkan:
    * SPV_KHR_ray_tracing
    * SPV_KHR_ray_query

  • VK_KHR_pipeline_library: this extension provides the ability to provide a set of shaders which can be linked into pipelines. With ray tracing it can be useful when incrementally constructing ray tracing pipelines.
  • VK_KHR_deferred_host_operations: this extension allows expensive driver operations to be offloaded to application-managed CPU thread pools which can enable work to be done on background threads or parallelized across multiple cores. With ray tracing this can be used for ray tracing pipeline compilation or CPU-based acceleration structure construction.

 
Two interesting resources have been published:

 
NVIDIA has released a developer driver (442.75 for Windows and 440.66.02 for Linux) with new ray tracing extensions:

New:
– Multi-vendor Vulkan ray tracing
VK_KHR_ray_tracing
VK_KHR_deferred_host_operations
VK_KHR_pipeline_library

– VK_EXT_pipeline_creation_cache_control

– VK_NV_device_generated_commands
For details see the new device generated command developer blog – Replaces the now deprecated VK_NVX_device_generated_commands

– Added support for a new device-local VkMemoryType which is host-coherent and host-visible

Fixes:
– fixes for HDR presentation on Windows

You can download this driver from this page.

 

Tutorials and Code Samples