gfx-rs/wgpu · error
Feature `EXPERIMENTAL_RAY_TRACING_PIPELINES` not enabled
Error message
Feature `EXPERIMENTAL_RAY_TRACING_PIPELINES` not enabled
What it means
Panic in the Vulkan encoder's trace_rays: device.extension_fns.ray_tracing was None, i.e. the VK ray tracing extension functions were not loaded because the corresponding experimental ray tracing feature was not enabled on the device at creation.
Solutions
- Create the device with the experimental ray tracing features enabled
- Only call trace_rays after verifying the device supports ray tracing
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at wgpu-hal/src/vulkan/command.rs:1436 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of gfx-rs/wgpu@3e11ff59bf (2026-09-03).
Data as JSON: /api/errors/c34226cd38c20fec.
Report an issue: GitHub.
Appendix: source
Thrown at wgpu-hal/src/vulkan/command.rs:1436
&mut self,
count: [u32; 3],
ray_generation_group_data: crate::PipelineGroupData<super::Buffer>,
miss_group_data: crate::PipelineGroupData<super::Buffer>,
intersection_group_data: crate::PipelineGroupData<super::Buffer>,
) {
let ray_tracing_functions = self
.device
.extension_fns
.ray_tracing
.as_ref()
.expect("Feature `EXPERIMENTAL_RAY_TRACING` not enabled");
let ray_tracing_pipeline_functions = self
.device
.extension_fns
.ray_tracing_pipelines
.as_ref()
.expect("Feature `EXPERIMENTAL_RAY_TRACING_PIPELINES` not enabled");
let get_device_address = |buffer: &super::Buffer| unsafe {
ray_tracing_functions
.buffer_device_address
.get_buffer_device_address(
&vk::BufferDeviceAddressInfo::default().buffer(buffer.raw),
)
};
unsafe {
ray_tracing_pipeline_functions.cmd_trace_rays(
self.raw_handle(),
&vk::StridedDeviceAddressRegionKHR {
device_address: get_device_address(ray_generation_group_data.buffer)
+ ray_generation_group_data.offset,
stride: ray_generation_group_data.stride,
size: ray_generation_group_data.stride /* no need for multiplying by count, vulkan requires the ray gen sbt to be just one group */,
},View on GitHub (pinned to 3e11ff59bf)