Pixelate, repeat, subdivide: Hydra to Processing

Hi! I am trying to replicate this code in processing, but I don’t even know where to start…

Should I use a shadder for this pixelate/subdivision effect or something else?

Here is the part of the could that I managed to grab (probably the first oscillators are missing):

_p = () => parseStrudel(window.pattern2)()
currP = 0
update = () => {
 currP = _p()
}

bpm = 60

src(o0)
.modulateHue(o0, 0.1)
.modulate(noise(3).pixelate(6,6), () => {
 if(currP === 5) return 0.01
 if(currP === 1) return -0.1
 return 0.00
})
//.hue(0.004)
.brightness(-0.001)
.scrollY(() => {
 if(currP ===3) return -0.02
 return -0.00
})
.scrollX(() => {
 if(currP ===4) return 0.02
 return 0.00
})
.modulate(gradient().brightness(-0.5), () => {
if (currP === 2) return -0.05
return -0.0
})
.layer(
osc(0.2,0.03,1.8)
.hue(()=> currP * 0.2)
.mask(
shape(4, 0.3, 0.04)
.repeat(()=> currP, 1).scrollY(0,0.14)
).contrast(40))
//.luma(0.)
.out()

osc(2).out

hush()

thanks!!

1 Like