Skip to content

Commit

Permalink
Fix array_texture example (#7543)
Browse files Browse the repository at this point in the history
# Objective

- Shader error cause by a missing import.
- `pbr_functions.wgsl` was missing an import for the `ambient_light()` function, as `array_texture` doesn't import it.
- Closes #7542.

## Solution

- Add`#import bevy_pbr::pbr_ambient` into `array_texture`
  • Loading branch information
aevyrie committed Feb 7, 2023
1 parent ea2ecd4 commit f3a23fd
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions assets/shaders/array_texture.wgsl
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#import bevy_pbr::shadows
#import bevy_pbr::fog
#import bevy_pbr::pbr_functions
#import bevy_pbr::pbr_ambient

@group(1) @binding(0)
var my_array_texture: texture_2d_array<f32>;
Expand Down

0 comments on commit f3a23fd

Please sign in to comment.