Don't include compute in shadow push constant shader stages

(avoids panic on metal backend: https://gitlab.com/veloren/veloren/-/issues/1951)
This commit is contained in:
Imbris 2024-02-11 12:29:07 -05:00
parent 756dbdd9d7
commit 59596874e1
2 changed files with 2 additions and 2 deletions

View File

@ -234,7 +234,7 @@ impl PointShadowPipeline {
device.create_pipeline_layout(&wgpu::PipelineLayoutDescriptor {
label: Some("Point shadow pipeline layout"),
push_constant_ranges: &[wgpu::PushConstantRange {
stages: wgpu::ShaderStages::all(),
stages: wgpu::ShaderStages::VERTEX_FRAGMENT,
range: 0..64,
}],
bind_group_layouts: &[&global_layout.globals, &terrain_layout.locals],

View File

@ -658,7 +658,7 @@ impl<'frame> Drawer<'frame> {
(0../*20*/1).for_each(|point_light| {
render_pass.set_push_constants(
wgpu::ShaderStages::all(),
wgpu::ShaderStages::VERTEX_FRAGMENT,
0,
&data[(6 * (point_light + 1) * STRIDE + face as usize * STRIDE)
..(6 * (point_light + 1) * STRIDE + (face + 1) as usize * STRIDE)],