https://dgtized.github.io/shimmers/#/sketches
Source: https://github.com/dgtized/shimmers
As of 2022-09-21, that’s 170 sketches! Each is its own little Clojurescript file.
Here’s a small one:
defn rain [noise]
(let [x0 (q/random (- 140) (+ 140 (q/width)))
(+ (* 3 (q/random-gaussian))
angle (q/radians (* 110 (- 1 noise))))
(+ x0 (* 200 (q/cos angle)))
x1 (- (rand) 0.2)
s0 (+ s0 (q/random noise))]
s1 (0.1 noise))
(q/stroke-weight (q/random 0 (q/height) s0)
(q/line (q/lerp x0 x1 s0) (q/lerp 0 (q/height) s1))))
(q/lerp x0 x1 s1) (q/lerp
defn draw [_]
(0 10)
(q/background 255 128)
(q/stroke let [noise (q/noise 0 (/ (q/frame-count) 1000))]
(;; (q/print-every-n-millisec 500 noise)
dotimes [_ (rand-int (* 8 noise))]
(
(rain noise))))
(sketch/defquil precipitation:created-at "2021-01-19"
:size [800 600]
:draw draw
:middleware [m/fun-mode framerate/mode])