{"record":{"id":"de2e547d66869885","repo":"gfx-rs/wgpu","slug":"feature-draw-indirect-count-not-enabled","errorCode":null,"errorMessage":"Feature `DRAW_INDIRECT_COUNT` not enabled","messagePattern":"Feature `DRAW_INDIRECT_COUNT` not enabled","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"wgpu-hal/src/vulkan/command.rs","lineNumber":1283,"sourceCode":"        count_offset: wgt::BufferAddress,\n        max_count: u32,\n    ) {\n        let stride = size_of::<wgt::DrawIndirectArgs>() as u32;\n        match self.device.extension_fns.draw_indirect_count {\n            Some(ref t) => {\n                unsafe {\n                    t.cmd_draw_indirect_count(\n                        self.active,\n                        buffer.raw,\n                        offset,\n                        count_buffer.raw,\n                        count_offset,\n                        max_count,\n                        stride,\n                    )\n                };\n            }\n            None => panic!(\"Feature `DRAW_INDIRECT_COUNT` not enabled\"),\n        }\n    }\n    unsafe fn draw_indexed_indirect_count(\n        &mut self,\n        buffer: &super::Buffer,\n        offset: wgt::BufferAddress,\n        count_buffer: &super::Buffer,\n        count_offset: wgt::BufferAddress,\n        max_count: u32,\n    ) {\n        let stride = size_of::<wgt::DrawIndexedIndirectArgs>() as u32;\n        match self.device.extension_fns.draw_indirect_count {\n            Some(ref t) => {\n                unsafe {\n                    t.cmd_draw_indexed_indirect_count(\n                        self.active,\n                        buffer.raw,\n                        offset,","sourceCodeStart":1265,"sourceCodeEnd":1301,"githubUrl":"https://github.com/gfx-rs/wgpu/blob/3e11ff59bf3f9795d285ecc045014089640d7248/wgpu-hal/src/vulkan/command.rs#L1265-L1301","documentation":"Panic raised when the indirect-count draw path is taken on a Vulkan device where the draw_indirect_count extension functions were not loaded. The match on device.extension_fns.draw_indirect_count falls into the None arm, meaning Features::DRAW_INDIRECT_COUNT was not enabled on the device.","triggerScenarios":"Thrown at wgpu-hal/src/vulkan/command.rs:1283 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Enable Features::DRAW_INDIRECT_COUNT when creating the device and verify adapter support via features().contains()","Fall back to a plain draw_indirect call with a known instance count when the feature is unavailable"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"3e11ff59bf3f9795d285ecc045014089640d7248","analyzedAt":"2026-09-03T01:43:21.459Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-10T07:17:11.731Z"}