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.

Constants

TRANSMISSION_OPAQUE_OPTICAL_DEPTH

#
const TRANSMISSION_OPAQUE_OPTICAL_DEPTH: f32 = 6.931471806

Functions

unresolved_wave_roughness

#
Used by 1 shader in bevy-aqua-core 0.1.3

Dupuy et al. 2013 LEADR-style slope filtering. A pixel cannot resolve waves shorter than twice its projected world footprint. Integrate each shipped wavelength band’s measured slope variance below that Nyquist cutoff. The logarithmic partial-band term matches the generator’s octave partition.

fn unresolved_wave_roughness (
world_xz: vec2<f32>,
to_view: vec3<f32>,
lod_alpha: f32,
lighting_normal_strength: f32,
filtered_detail_variance: f32
) -> f32

deep_water_weight

#
Used by 1 shader in bevy-aqua-core 0.1.3
fn deep_water_weight (
water_depth: f32
) -> f32

depth_aware_body_albedo

#
fn depth_aware_body_albedo (
water_depth: f32,
deep_body_albedo: vec3<f32>
) -> vec3<f32>

far_field_water

#
Used by 1 shader in bevy-aqua-core 0.1.3
fn far_field_water (
world_position: vec4<f32>,
surface_level: f32,
geometric_normal: vec3<f32>,
to_view: vec3<f32>,
wave_height: f32,
water_depth: f32
) -> vec3<f32>

camera_eye_depth

#
fn camera_eye_depth (
uv: vec2<f32>,
raw_depth: f32
) -> f32

empty_camera_depth_path

#
Used by 1 shader in bevy-aqua-core 0.1.3
fn empty_camera_depth_path () -> CameraDepthPath

camera_depth_path

#
Used by 1 shader in bevy-aqua-core 0.1.3
fn camera_depth_path ( ) -> CameraDepthPath

camera_depth_debug_from_path

#

Reimplementation of the approach in Crest OceanEmission.hlsl:195-242. The opaque camera depth, never SeaFloorDepth LodData, determines the view-ray water path and whether a refracted sample landed on geometry in front of the water.

fn camera_depth_debug_from_path (
normal: vec3<f32>,
) -> CameraDepthDebug

opaque_background

#

Transmission samples the opaque buffer at full resolution. Distortion comes only from the displacement normal; no roughness mip or blur is used.

fn opaque_background (
subview_uv: vec2<f32>
) -> vec3<f32>

resolve_near_surface

#
Used by 1 shader in bevy-aqua-core 0.1.3
fn resolve_near_surface (
surface_lod: u32,
geometric_normal: vec3<f32>,
far_tier: f32,
mode: u32
) -> NearSurface

sample_water_medium

#
Used by 1 shader in bevy-aqua-core 0.1.3
fn sample_water_medium (
surface_lod: u32,
lighting_normal: vec3<f32>,
to_view: vec3<f32>,
mode: u32
) -> MediumState

illuminate_bed

#
fn illuminate_bed (
scene_colour: vec3<f32>,
medium: MediumState,
) -> vec3<f32>

resolve_transmission

#
Used by 1 shader in bevy-aqua-core 0.1.3
fn resolve_transmission (
normal: vec3<f32>,
scatter_colour: vec3<f32>,
medium: MediumState,
foam: FoamState,
mode: u32
) -> TransmissionState
Contents