bevy/crates/bevy_render
Charles 6c2f78f449 Validate vertex attribute format on insert (#5259)
# Objective

- Validate the format of the values with the expected attribute format.
- Currently, if you pass the wrong format, it will crash somewhere unrelated with a very cryptic error message, so it's really hard to debug for beginners.

## Solution

- Compare the format and panic when unexpected format is passed

## Note

- I used a separate `error!()` for a human friendly message because the panic message is very noisy and hard to parse for beginners. I don't mind changing this to only a panic if people prefer that.
- This could potentially be something that runs only in debug mode, but I don't think inserting attributes is done often enough for this to be an issue.


Co-authored-by: Charles <IceSentry@users.noreply.github.com>
2022-07-11 14:11:31 +00:00
..
macros Better Materials: AsBindGroup trait and derive, simpler Material trait (#5053) 2022-06-30 23:48:46 +00:00
src Validate vertex attribute format on insert (#5259) 2022-07-11 14:11:31 +00:00
Cargo.toml Extract resources into their target location (#5271) 2022-07-10 21:04:35 +00:00