Bevy Shader Explorer
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.
Packages
›
bevy_pbr
0.20.0
0.15.0
0.15.1
0.15.2
0.15.3
0.15.4
0.16.0
0.16.1
0.16.2
0.17.0
0.17.1
0.17.2
0.17.3
0.18.0
0.18.1
0.19.0
0.19.1
›
lightmap.wesl
Save
Bindings
lightmaps_textures
#
@
group
(
2
)
@
binding
(
4
)
var
lightmaps_textures:
binding_array<
texture_2d
<
f32
>, 4>
lightmaps_samplers
#
@
group
(
2
)
@
binding
(
5
)
var
lightmaps_samplers:
binding_array<
sampler
, 4>
lightmaps_texture
#
@
group
(
2
)
@
binding
(
4
)
var
lightmaps_texture:
texture_2d
<
f32
>
lightmaps_sampler
#
@
group
(
2
)
@
binding
(
5
)
var
lightmaps_sampler:
sampler
Functions
lightmap
#
Samples the lightmap, if any, and returns indirect illumination from it.
fn
lightmap
(
uv:
vec2
<
f32
>
,
exposure:
f32
,
instance_index:
u32
)
->
vec3
<
f32
>
lightmap_size
#
fn
lightmap_size
(
lightmap_slot:
u32
)
->
vec2
<
u32
>
sample
#
fn
sample
(
uv:
vec2
<
f32
>
,
lightmap_slot:
u32
)
->
vec3
<
f32
>
w0
#
fn
w0
(
a:
f32
)
->
f32
w1
#
fn
w1
(
a:
f32
)
->
f32
w2
#
fn
w2
(
a:
f32
)
->
f32
w3
#
fn
w3
(
a:
f32
)
->
f32
g0
#
fn
g0
(
a:
f32
)
->
f32
g1
#
fn
g1
(
a:
f32
)
->
f32
h0_approx
#
fn
h0_approx
(
a:
f32
)
->
f32
h1_approx
#
fn
h1_approx
(
a:
f32
)
->
f32
Contents
Bindings
lightmaps_textures
lightmaps_samplers
lightmaps_texture
lightmaps_sampler
Functions
lightmap
lightmap_size
sample
w0
w1
w2
w3
g0
g1
h0_approx
h1_approx
Samples the lightmap, if any, and returns indirect illumination from it.