Skip to content

Commit

Permalink
Better error message for unsuported shader features
Browse files Browse the repository at this point in the history
  • Loading branch information
myisaak committed Aug 7, 2021
1 parent 97d8e4e commit 347ddb7
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion crates/bevy_render/src/shader/shader_reflect.rs
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,19 @@ fn reflect_binding(
filtering: false,
},
),
_ => panic!("Unsupported bind type {:?}.", binding.descriptor_type),
_ => {
let ReflectDescriptorBinding {
descriptor_type,
name,
set,
binding,
..
} = binding;
panic!(
"Unsupported shader bind type {:?} (name '{}', set {}, binding {})",
descriptor_type, name, set, binding
);
}
};

let shader_stage = match shader_stage {
Expand Down

0 comments on commit 347ddb7

Please sign in to comment.