added random seed
All checks were successful
CI / React UI Build (push) Successful in 11s
CI / Native Windows Build And Tests (push) Successful in 1m33s
CI / Windows Release Package (push) Successful in 2m11s

This commit is contained in:
2026-05-08 13:38:27 +10:00
parent 5eff189bbf
commit 7035cde8c8
10 changed files with 35 additions and 29 deletions

View File

@@ -14,13 +14,14 @@ float4 shadeVideo(ShaderContext context)
float safeScale = max(scale, 0.001);
float safeRingRadius = max(ringRadius, 0.001);
float safeTightness = max(tightness, 0.001);
float time = context.time * speed;
float seed = context.startupRandom;
float time = context.time * speed + seed * 37.0;
float2 p = (fragCoord + fragCoord - resolution) / resolution.y / safeScale;
p -= center;
p -= center + float2(sin(seed * 6.2831853), cos(seed * 6.2831853)) * 0.035;
float iterator = 0.2;
float2 diagonal = float2(-1.0, 1.0);
float2 diagonal = normalize(float2(-1.0 + seed * 0.5, 1.0 - seed * 0.35));
float2 blackholeCenter = p - iterator * diagonal;
float gravity = iterator * strength / max(dot(blackholeCenter, blackholeCenter), 0.0001);
float2 skew = diagonal / (0.1 + gravity);