Search across packages, versions, files, declarations, and comments. Use multiple terms to narrow results (AND), and add @vertex, @fragment, or @compute to filter by shader stage.
1#import bevy_pbr::forward_io::VertexOutput
3#ifdef CUBEMAP_ARRAY
4@group(2) @binding(0) var base_color_texture: texture_cube_array<f32>;
5#else
6@group(2) @binding(0) var base_color_texture: texture_cube<f32>;
7#endif
9@group(2) @binding(1) var base_color_sampler: sampler;
11@fragment
12fn fragment(
13 mesh: VertexOutput,
14) -> @location(0) vec4<f32> {
15 let fragment_position_view_lh = mesh.world_position.xyz * vec3<f32>(1.0, 1.0, -1.0);
16 return textureSample(
17 base_color_texture,
18 base_color_sampler,
19 fragment_position_view_lh
20 );
Contents