bevy/crates/bevy_pbr/src/render
François ae6bc08a58
Fix wireframe for skinned/morphed meshes (#9734)
# Objective

- Fixes #6662 
- Wireframe crash for skinned meshes:
```
wgpu error: Validation Error

Caused by:
    In Device::create_render_pipeline
      note: label = `opaque_mesh_pipeline`
    Error matching ShaderStages(VERTEX) shader requirements against the pipeline
    Location[4] Uint32x4 interpolated as Some(Flat) with sampling None is not provided by the previous stage outputs
    Input is not provided by the earlier stage in the pipeline
```
- Wireframe crash for morphed meshes:
```
wgpu error: Validation Error

Caused by:
    In a RenderPass
      note: encoder = `<CommandBuffer-(0, 14, Metal)>`
    In a draw command, indexed:true indirect:false
      note: render pipeline = `opaque_mesh_pipeline`
    The pipeline layout, associated with the current render pipeline, contains a bind group layout at index 1 which is incompatible with the bind group layout associated with the bind group at 1
```

## Solution


- Fix the locations for skinned meshes in the wireframe shader
- Add the morph key to the wireframe specialisation key
- Morph the vertex in the wireframe shader


https://github.com/bevyengine/bevy/assets/8672791/ce0a9584-bd28-4d74-9c3f-256602e6fac5
2023-09-11 19:14:15 +00:00
..
clustered_forward.wgsl improve shader import model (#5703) 2023-06-27 00:29:22 +00:00
fog.rs Bevy Asset V2 (#8624) 2023-09-07 02:07:27 +00:00
fog.wgsl improve shader import model (#5703) 2023-06-27 00:29:22 +00:00
light.rs Remove useless single tuples and trailing commas (#9720) 2023-09-08 21:46:54 +00:00
mesh_bindings.rs Use GpuArrayBuffer for MeshUniform (#9254) 2023-07-30 13:17:08 +00:00
mesh_bindings.wgsl Use GpuArrayBuffer for MeshUniform (#9254) 2023-07-30 13:17:08 +00:00
mesh_functions.wgsl Use instancing for sprites (#9597) 2023-09-02 18:03:19 +00:00
mesh_types.wgsl Use instancing for sprites (#9597) 2023-09-02 18:03:19 +00:00
mesh_vertex_output.wgsl Explicitly make instance_index vertex output @interpolate(flat) (#9675) 2023-09-02 18:11:13 +00:00
mesh_view_bindings.wgsl improve shader import model (#5703) 2023-06-27 00:29:22 +00:00
mesh_view_types.wgsl EnvironmentMapLight support for WebGL2 (#7737) 2023-02-20 00:02:40 +00:00
mesh.rs Bevy Asset V2 (#8624) 2023-09-07 02:07:27 +00:00
mesh.wgsl Reduce the size of MeshUniform to improve performance (#9416) 2023-08-15 06:00:23 +00:00
mod.rs Add morph targets (#8158) 2023-06-22 20:00:01 +00:00
morph.rs Split ComputedVisibility into two components to allow for accurate change detection and speed up visibility propagation (#9497) 2023-09-01 13:00:18 +00:00
morph.wgsl Fix typos throughout the project (#9090) 2023-07-10 00:11:51 +00:00
parallax_mapping.wgsl improve shader import model (#5703) 2023-06-27 00:29:22 +00:00
pbr_ambient.wgsl improve shader import model (#5703) 2023-06-27 00:29:22 +00:00
pbr_bindings.wgsl improve shader import model (#5703) 2023-06-27 00:29:22 +00:00
pbr_functions.wgsl Use GpuArrayBuffer for MeshUniform (#9254) 2023-07-30 13:17:08 +00:00
pbr_lighting.wgsl Fix typos throughout the project (#9090) 2023-07-10 00:11:51 +00:00
pbr_prepass.wgsl fix prepass normal_mapping (#8978) 2023-06-29 00:28:34 +00:00
pbr_types.wgsl Add parallax mapping to bevy PBR (#5928) 2023-04-15 10:25:14 +00:00
pbr.wgsl Use GpuArrayBuffer for MeshUniform (#9254) 2023-07-30 13:17:08 +00:00
shadows.wgsl improve shader import model (#5703) 2023-06-27 00:29:22 +00:00
skinning.wgsl improve shader import model (#5703) 2023-06-27 00:29:22 +00:00
utils.wgsl Screen Space Ambient Occlusion (SSAO) MVP (#7402) 2023-06-18 21:05:55 +00:00
wireframe.wgsl Fix wireframe for skinned/morphed meshes (#9734) 2023-09-11 19:14:15 +00:00