Show HN: I made a generative online drum machine with ClojureScript

37 pointsposted 4 hours ago
by chr15m

11 Comments

chaosprint

35 minutes ago

> "The audio engine is built on a declarative audio graph (using `virtual-audio-graph`), inspired by React's virtual DOM, which makes managing the Web Audio API much cleaner. If you're building web based audio apps I highly recommend checking out this library. "

when you have more and more interactions on the gui web audio api will become a problem, check out audioworklet.

I am developing https://glicol.org/ and it has a js port on https://glicol.js.org/ a typical usecase is drum machine with very high time accuracy

amelius

4 minutes ago

Thanks for making this a web app, and not some app that only runs on half of the phones/tablets out there.

iamben

2 hours ago

This is great fun, congrats!

2 small requests that (I think) would help with the UX: consider moving (or duplicating) the play button - maybe directly in the middle below the editor, or on that panel itself. It took me a few confusing seconds to realise where it was. Also, could you consider making each fourth (or first) column a very slightly lighter grey? So if I want my kick on 1, 3, 10 and 11 it's really easy to see where to click without counting?

monneyboi

2 hours ago

Dope!

One thing I notice is that the generated beats are very alike. Yeah it makes sense to play snare on the 2 and the 4, and to have kicks always fall on the downbeat, but you'd get more creative grooves if you allow for some more variation there.

It could even be a slider that allows you to stray away from the common patterns.

dpoljak

2 hours ago

Really cool! How come you've chosen ClojureScript, and did you regret that choice in the 2 years you've been working on this?

To be clear, this is pure curiosity on my part as I love Clojure(Script) and am consistently missing it during my day job.

raspasov

an hour ago

I think the question is for other projects: How come you've not chosen ClojureScript? ;)

raspasov

an hour ago

Very nice! ClojureScript rocks. Just curious, did you use any React for this, or is it vanilla HTML interop?

diggan

an hour ago

> view-source:https://dopeloop.ai/beat-maker/js/main.js

> CTRL+F "React"

> 93 matches

Somewhere there is a React lurking :)

Guessing it's via Reagent as it's also mentioned 8 times, and is a fairly traditional approach to frontend with ClojureScript.

thw_9a83c

3 hours ago

Nice work! Nice that you also implemented an MPC-style swing. How do you generate samples? Are they also procedurally generated or are they chosen from a fixed set of samples? I suppose you're not planning to release any sources for this...

phrygian

an hour ago

very nice, enjoy listening to the beats. also good to see something come out of Clojure land after a while

sakrist

an hour ago

awesome tool! would be more usable to scroll horizontally as one page and ability to add verticals one at a time.