Back home 🏡 WGSL Spec Bevy WGSL Functions

tonemapping_test_patterns.wgsl

Functions

color_sweep

#
Sweep across hues on y axis with value from 0.0 to +15EV across x axis quantized into 24 steps for both axis.
fn color_sweep(uv_input: vec2<f32>) -> vec3<f32>
Parameter Type
uv_input vec2<f32>
Returns: vec3<f32>

hsv_to_srgb

#
fn hsv_to_srgb(c: vec3<f32>) -> vec3<f32>
Parameter Type
c vec3<f32>
Returns: vec3<f32>

continuous_hue

#
Generates a continuous sRGB sweep.
fn continuous_hue(uv: vec2<f32>) -> vec3<f32>
Parameter Type
uv vec2<f32>
Returns: vec3<f32>

fragment

#
@fragment
fn fragment(in: VertexOutput) -> @location(0) vec4<f32>
Parameter Type
in VertexOutput
Returns: @location(0) vec4<f32>