createCanvas(windowWidth, windowHeight, WEBGL)
font = await loadFont("https://fonts.gstatic.com/s/inter/v18/UcCO3FwrK3iLTeHuS_nVMrMxCp50SjIw2boKoduKmMEVuLyfMZhrib2Bg-4.ttf")
prev = createFramebuffer({ antialias: true, format: FLOAT, width: width * 1.2, height: height * 1.2 })
next = createFramebuffer({ antialias: true, format: FLOAT, width: width * 1.2, height: height * 1.2 })
myShader = baseMaterialShader().modify({})
myShader._fragSrc = myShader._fragSrc.replace(
'inputs.color.rgb /= inputs.color.a;',
'if (inputs.color.a > 0.) inputs.color.rgb /= inputs.color.a;'
[next, prev] = [prev, next];
map(noise(millis()*0.0001), 0, 1, -1, 1) * width * 0.01,
map(noise(millis()*0.0001, 1000), 0, 1, -1, 1) * height * 0.01,
const dist = Math.hypot(mouseX-pmouseX, mouseY-pmouseY)
const steps = max(1, ceil(dist / 8))
const d = min(width, height) * (0.15 + 0.05 * sin(millis() * 0.005))
for (let i = 0; i < steps; i++) {
circle(mouseX - width/2, mouseY - height/2, d)
circle(map(i, 0, steps-1, pmouseX, mouseX) - width/2, map(i, 0, steps-1, pmouseY, mouseY) - height/2, d)
text('2.0', mouseX-width/2 - d * 0.4, mouseY-height/2 + d/4)