bevy/crates/bevy_render/src
Carter Anderson 1248a639ee EnumVariantMeta derive (#1972)
There are cases where we want an enum variant name. Right now the only way to do that with rust's std is to derive Debug, but this will also print out the variant's fields. This creates the unfortunate situation where we need to manually write out each variant's string name (ex: in #1963), which is both boilerplate-ey and error-prone. Crates such as `strum` exist for this reason, but it includes a lot of code and complexity that we don't need.

This adds a dead-simple `EnumVariantMeta` derive that exposes `enum_variant_index` and `enum_variant_name` functions. This allows us to make cases like #1963 much cleaner (see the second commit). We might also be able to reuse this logic for `bevy_reflect` enum derives.
2021-04-21 23:46:54 +00:00
..
camera Moved events to ECS (#1823) 2021-04-13 20:36:37 +00:00
mesh EnumVariantMeta derive (#1972) 2021-04-21 23:46:54 +00:00
pass Update to wgpu-rs 0.7 (#542) 2021-01-31 20:06:42 -08:00
pipeline Error message improvements for shader compilation/gltf loading (#1786) 2021-04-13 02:56:30 +00:00
render_graph Cargo fmt with unstable features (#1903) 2021-04-21 23:19:34 +00:00
renderer Implement RenderResource for Box<T> (#1893) 2021-04-14 23:58:25 +00:00
shader change how to select bevy-glsl-to-spirv or shaderc (#1819) 2021-04-19 21:28:30 +00:00
texture Moved events to ECS (#1823) 2021-04-13 20:36:37 +00:00
wireframe Remove remaining camerapos bindings (#1708) 2021-03-22 18:10:35 +00:00
color.rs Cargo fmt with unstable features (#1903) 2021-04-21 23:19:34 +00:00
colorspace.rs color spaces and representation (#1572) 2021-03-17 23:59:51 +00:00
draw.rs Frustum Culling (for Sprites) (#1492) 2021-03-24 21:29:53 +00:00
entity.rs Bevy ECS V2 (#1525) 2021-03-05 07:54:35 +00:00
lib.rs don't panic when no RenderResourceContext can be found (#1971) 2021-04-20 21:44:32 +00:00