Direct3D 12 Raytracing HLSL Shaders
The following HLSL shaders support the Direct3D 12 raytracing pipeline. These shaders are functions compiled into a library, with target model lib_6_3, and identified by an attribute [shader("shadertype")] on the shader function. See Intrinsics and System Values to see what is allowed for each shader type.
In this section
|Any Hit Shader
||A shader that is invoked when ray intersections are not opaque.
||A shader that is invoked from another shader with the CallShader intrinsic.
|Closest Hit Shader
||A shader that is invoked when it is enabled and the closest hit has been determined or ray intersection search ended.
||A shader that is used to implement custom intersection primitives for rays intersecting an associated bounding volume (bounding box).
||A shader that is invoked when no ray intersections are found or accepted.
|Ray Generation Shader
||A shader that calls TraceRay to generate rays.