@@ -256,8 +256,12 @@ class HeaderCanvas extends Base {
256256 for ( let x = 0 ; x <= width ; x += step ) {
257257 let { offsetY, intensity} = me . getStreamOffset ( x , height ) ;
258258
259- let timeShift = me . time * 2 ,
260- sine = Math . sin ( ( x * 0.04 ) - timeShift ) * baseAmp ,
259+ // FREQUENCY MODULATION:
260+ // Vary the phase speed along X to stretch/compress the wave.
261+ // We use a low-frequency sine to modulate the input to the high-frequency sine.
262+ let freqMod = Math . sin ( x * 0.002 + me . time * 0.1 ) * 20 , // Slowly changing warp
263+ timeShift = me . time * 2 ,
264+ sine = Math . sin ( ( ( x + freqMod ) * 0.04 ) - timeShift ) * baseAmp ,
261265 noise = ( Math . random ( ) - 0.5 ) * hoverAmp * intensity ;
262266
263267 let y = centerY + sine - offsetY + noise ;
@@ -276,8 +280,10 @@ class HeaderCanvas extends Base {
276280 for ( let x = 0 ; x <= width ; x += step ) {
277281 let { offsetY, intensity} = me . getStreamOffset ( x , height ) ;
278282
279- let timeShift = me . time * 2 ,
280- sine = Math . sin ( ( x * 0.04 ) - timeShift + Math . PI ) * baseAmp ,
283+ // Same FM for coherence, just inverted phase
284+ let freqMod = Math . sin ( x * 0.002 + me . time * 0.1 ) * 20 ,
285+ timeShift = me . time * 2 ,
286+ sine = Math . sin ( ( ( x + freqMod ) * 0.04 ) - timeShift + Math . PI ) * baseAmp ,
281287 noise = ( Math . random ( ) - 0.5 ) * hoverAmp * intensity ;
282288
283289 let y = centerY + sine + offsetY + noise ;
0 commit comments