diff --git a/crates/viewer/re_renderer/shader/world_grid.wgsl b/crates/viewer/re_renderer/shader/world_grid.wgsl index 4dc5321b1e7cc..2c14b97e4f368 100644 --- a/crates/viewer/re_renderer/shader/world_grid.wgsl +++ b/crates/viewer/re_renderer/shader/world_grid.wgsl @@ -109,7 +109,7 @@ fn main_fs(in: VertexOutput) -> @location(0) vec4f { // // Tried smoothstep here, but didn't feel right even with lots of range tweaking. let line_density = 1.0 / max(width_in_grid_units.x, width_in_grid_units.y); - let grid_closeness_fade = linearstep(1.0, 10.0, line_density); + let grid_closeness_fade = linearstep(4.0, 20.0, line_density); intensity_regular *= grid_closeness_fade; // Every tenth line is a more intense, we call those "cardinal" lines. @@ -119,7 +119,7 @@ fn main_fs(in: VertexOutput) -> @location(0) vec4f { let distance_to_grid_line_cardinal = calc_distance_to_grid_line(in.scaled_world_plane_position * (1.0 / CARDINAL_LINE_FACTOR)); var cardinal_line_intensity = linearstep2(width_in_grid_units + line_anti_alias, width_in_grid_units - line_anti_alias, distance_to_grid_line_cardinal * CARDINAL_LINE_FACTOR); - let cardinal_grid_closeness_fade = linearstep(2.0, 10.0, line_density * CARDINAL_LINE_FACTOR); // Fade cardinal lines a little bit earlier (because it looks nicer) + let cardinal_grid_closeness_fade = linearstep(4.0, 20.0, line_density * CARDINAL_LINE_FACTOR); cardinal_line_intensity *= cardinal_grid_closeness_fade; // Combine all lines.