Skip to content

LiteFX::Rendering::Backends::DirectX12CommandBuffer::traceRays

Executes a query on a ray-tracing pipeline.

Synopsis

Declared in <litefx/backends/dx12.hpp>

[[dllimport, dllexport]] virtual void traceRays(
    UInt32 width,
    UInt32 height,
    UInt32 depth,
    ShaderBindingTableOffsets const& offsets,
    IDirectX12Buffer const& rayGenerationShaderBindingTable,
    IDirectX12Buffer const* missShaderBindingTable,
    IDirectX12Buffer const* hitShaderBindingTable,
    IDirectX12Buffer const* callableShaderBindingTable) const noexcept override;

Description

This method is only supported if the GraphicsDeviceFeatures::RayTracing feature is enabled.

Parameters

NameDescription
widthThe width of the ray-tracing query.
heightThe height of the ray-tracing query.
depthThe depth of the ray-tracing query.
offsetsThe offsets, sizes and strides for each shader binding table.
rayGenerationShaderBindingTableThe shader binding table that contains the ray generation shader.
missShaderBindingTableThe shader binding table that contains the miss shaders.
hitShaderBindingTableThe shader binding table that contains the hit shaders.
callableShaderBindingTableThe shader binding table that contains the callable shaders.