Closed as not planned
Closed as not planned
Description
Description
When setting a pipeline-overridable shader constant to f64::INFINITY
, code fails with an error on certain platforms in various configurations. I've only been able to catch this on Windows as of now.
Repro steps
device.create_render_pipeline(&wgpu::RenderPipelineDescriptor {
label: None,
layout: Some(&pipeline_layout),
vertex: wgpu::VertexState {
module: &shader,
entry_point: "vs_main",
buffers: &[],
compilation_options: wgpu::PipelineCompilationOptions {
constants: &HashMap::new().tap_mut(|x| {
x.insert(String::from("1000"), f64::INFINITY);
}),
..Default::default()
},
},
/* ... */
}
Expected vs observed behavior
This results in a crash with a message saying to report the issue. Not really sure which is the best way to handle this case otherwise, but at least it should not behave like that.
Platform
Windows 11
wgpu = "22.1.0"
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
Done