Skip to content

Commit ef8969a

Browse files
bennettfarkasclaude
andcommitted
Add rightward flow animation to stream exploration
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 74d7504 commit ef8969a

1 file changed

Lines changed: 8 additions & 7 deletions

File tree

stream-exploration/index.html

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -125,9 +125,10 @@
125125
126126
// Noise-modulated center line — subtle life
127127
float noiseScale = 1.8;
128-
float centerNoise = snoise(vec2(x * noiseScale + 0.3, uTime * 0.10)) * 0.028
129-
+ snoise(vec2(x * noiseScale * 2.5 + 5.0, uTime * 0.14 + 3.0)) * 0.014
130-
+ snoise(vec2(x * 5.0 - uTime * 0.18, 12.0)) * 0.005;
128+
float flow = uTime * 0.06;
129+
float centerNoise = snoise(vec2(x * noiseScale + 0.3 - flow, uTime * 0.10)) * 0.028
130+
+ snoise(vec2(x * noiseScale * 2.5 + 5.0 - flow * 1.5, uTime * 0.14 + 3.0)) * 0.014
131+
+ snoise(vec2(x * 5.0 - uTime * 0.18 - flow * 2.0, 12.0)) * 0.005;
131132
// Magnetic attraction — stream bends toward cursor
132133
float mdx = x - uMouse.x;
133134
float attract = 0.04 * exp(-(mdx * mdx) / 0.03);
@@ -142,8 +143,8 @@
142143
143144
// Half width with gentle breathing
144145
float hw = getHalfWidth(x);
145-
float widthNoise = snoise(vec2(x * 3.0 + 10.0, uTime * 0.12 + 7.0)) * 0.010
146-
+ snoise(vec2(x * 6.0 - uTime * 0.08, 20.0)) * 0.004;
146+
float widthNoise = snoise(vec2(x * 3.0 + 10.0 - flow, uTime * 0.12 + 7.0)) * 0.010
147+
+ snoise(vec2(x * 6.0 - uTime * 0.08 - flow * 1.5, 20.0)) * 0.004;
147148
hw += widthNoise;
148149
hw = max(hw, 0.01);
149150
@@ -162,7 +163,7 @@
162163
float alpha = mix(outerGauss, gauss, 0.5);
163164
164165
// Add subtle noise to alpha for organic feel
165-
float alphaNoise = snoise(vec2(x * 5.0 + uTime * 0.05, y * 5.0 * aspect + uTime * 0.03)) * 0.08;
166+
float alphaNoise = snoise(vec2(x * 5.0 - flow * 1.5, y * 5.0 * aspect + uTime * 0.03)) * 0.08;
166167
alpha = clamp(alpha + alphaNoise * alpha, 0.0, 1.0);
167168
168169
alpha = pow(alpha, 0.55);
@@ -172,7 +173,7 @@
172173
float vPos = clamp(dist * 0.5 + 0.5, 0.0, 1.0);
173174
174175
// Add noise to vertical position for more organic color variation
175-
float vNoise = snoise(vec2(x * 3.0 + uTime * 0.07 + 20.0, y * 4.0 * aspect - uTime * 0.04)) * 0.13;
176+
float vNoise = snoise(vec2(x * 3.0 - flow * 2.0 + 20.0, y * 4.0 * aspect - uTime * 0.04)) * 0.13;
176177
vPos = clamp(vPos + vNoise, 0.0, 1.0);
177178
178179
// Color: blend warm and cool based on x

0 commit comments

Comments
 (0)