bevy/examples/shader
Kurt Kühnert 9e450f2827 Compute Pipeline Specialization (#3979)
# Objective

- Fixes #3970
- To support Bevy's shader abstraction(shader defs, shader imports and hot shader reloading) for compute shaders, I have followed carts advice and change the `PipelinenCache` to accommodate both compute and render pipelines.

## Solution

- renamed `RenderPipelineCache` to `PipelineCache`
- Cached Pipelines are now represented by an enum (render, compute)
- split the `SpecializedPipelines` into `SpecializedRenderPipelines` and `SpecializedComputePipelines`
- updated the game of life example

## Open Questions

- should `SpecializedRenderPipelines` and `SpecializedComputePipelines` be merged and how would we do that?
- should the `get_render_pipeline` and `get_compute_pipeline` methods be merged?
- is pipeline specialization for different entry points a good pattern




Co-authored-by: Kurt Kühnert <51823519+Ku95@users.noreply.github.com>
Co-authored-by: Carter Anderson <mcanders1@gmail.com>
2022-03-23 00:27:26 +00:00
..
animate_shader.rs Compute Pipeline Specialization (#3979) 2022-03-23 00:27:26 +00:00
compute_shader_game_of_life.rs Compute Pipeline Specialization (#3979) 2022-03-23 00:27:26 +00:00
custom_vertex_attribute.rs default() shorthand (#4071) 2022-03-01 20:52:09 +00:00
shader_defs.rs Compute Pipeline Specialization (#3979) 2022-03-23 00:27:26 +00:00
shader_instancing.rs Compute Pipeline Specialization (#3979) 2022-03-23 00:27:26 +00:00
shader_material.rs default() shorthand (#4071) 2022-03-01 20:52:09 +00:00
shader_material_glsl.rs default() shorthand (#4071) 2022-03-01 20:52:09 +00:00
shader_material_screenspace_texture.rs default() shorthand (#4071) 2022-03-01 20:52:09 +00:00