18
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-12-01 04:47:06 +01:00
Files
maszyna/rendering/common
lcddisplay 93df4f57bb Snow windscreen: the snow of the glass simulated on a map that keeps it
A glass of mat_snow_windscreen (the material of the "snow:" block, with a
mask of the wipers) gets a slot of the windscreen water storage, as the
glasses of the water could, and two maps of its snow (a step reads one,
writes the other): the snow, the water, how packed the snow is and the shape
of its flakes for each of 256 x 256 texels of its uv. water_snow.comp runs a
step a frame, both APIs:
- the flakes land as many as come to the glass facing the snow against the
  cab (and a few from the eddies), the dry ones bouncing off at speed;
- the blades take the snow they go over (a little stays, a wet trace) and
  push it ahead of themselves, leaving it as ridges at the ends of their
  sweeps; piled snow slips onto its neighbours into a wedge;
- the glass is warmer than the air (the cab is heated, less so at speed):
  above zero the snow melts into water, slush slides down, dry powder is
  blown along by the air at speed, the water runs and dries.
mat_snow_windscreen.frag draws the map: flakes from the atlas where the snow
is thin (water spots where it melted), a layer with a torn edge, as opaque as
it is thick, grey when wet, its relief from the slopes of the map; the wet
glass bends the picture behind through the post-processing. Without the
simulation the glass is drawn as before.

The glasses are found again when a material of the cab changes its kind
(the weather switched its shader). The drop passes run only for glasses of
the water. No assets change.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BqfRrTiBDaAyQ2gT6ZrnZD
2026-11-24 12:10:47 +01:00
..
2026-11-09 20:58:02 +01:00
2026-11-09 20:58:02 +01:00
2026-11-09 20:58:02 +01:00
2026-11-09 20:58:02 +01:00
2026-11-17 01:02:52 +01:00