Skip to content Skip to footer

Show HN: Web Audio Spring-Mass Synthesis by cochlear

11 Comments

  • Post Author
    danbmil99
    Posted March 15, 2025 at 12:00 am

    Very cool! I've often wondered whether one could procedurally generate sounds of objects interacting in a physics engine? This approach seems like a good place to start.

  • Post Author
    ta988
    Posted March 15, 2025 at 4:02 am

    This is fun, but if you reduce the tension and click a lot on it, it gets stuck with almost all the points at the top of the screen except one. Also weirdly in Firefox android it clicks a lot, not on chrome.

  • Post Author
    SoleilAbsolu
    Posted March 15, 2025 at 7:06 am

    Interesting, I'm into physical modeling and learning DSP.

    I did notice glitching in latest Firefox on a Mac, like I'd get running a DAW with too small a buffer…While the tab was open I got similar crackles and slightly delayed audio stream playing YouTube vids in other tabs.

  • Post Author
    xavriley
    Posted March 15, 2025 at 7:29 am

    This is cool – there’s some similar work here https://arxiv.org/pdf/2402.01571 which uses spiking neural networks (essentially Dirac pulses). I think the next step for this would be to learn a tonal embedding of the source alongside the event embedding so that you don’t have to rely on physically modelled priors. There’s some interesting work on guitar amp tone modelling that’s doing this already https://zenodo.org/records/14877373

  • Post Author
    akomtu
    Posted March 15, 2025 at 8:57 am

    Here's a simple, but high quality model of piano and violin: https://mattdailis.github.io/simulating-strings/resources/ph…

  • Post Author
    chaosprint
    Posted March 15, 2025 at 10:02 am

    Great demo.

    I used to do some web audio and tonejs works, but later switched to rust and glicol for sound synthesis.

    For example, this handwritten dattorro reverb:

    https://glicol.org/demo#handmadedattorroreverb

    This karplus-stress-tester may also be interesting to you.

    https://jackschaedler.github.io/karplus-stress-tester/

    In short, I think to study more powerful physics synthesis, you need to consider the technology stack of

    – rust -> wasm
    – audioworklet
    – sharedarraybuffer

    Visual can rely on wgpu. Of course, webgl is enough in this case imho.

    If it is purely desktop, you can consider using the physics library in bevy.

  • Post Author
    matt123456789
    Posted March 15, 2025 at 11:41 am

    First of all – very cool, played with this for a few minutes before discovering the following bug:

    In Safari (iOS 18.3.1) if you set the Mass slider to 0 and increase Tension, not only does the app crash, but a repeated clicking noise starts, and persists, even after the tab is closed – even after Safari itself is closed! Seems to be a Safari bug. I have reproduced it 3x.

    If you reproduce this and want the noise to go away you have to start another app that tries to play sound.

  • Post Author
    curtisszmania
    Posted March 15, 2025 at 12:59 pm

    [dead]

  • Post Author
    trial3
    Posted March 15, 2025 at 1:50 pm

    amazing! there are a couple settings here where it sounded like how i wish the String engine on my old OP-1 sounded. the random setting is really fun

  • Post Author
    lfsh
    Posted March 15, 2025 at 2:39 pm

    If you like this you might also like Anukari's 3D Physics Synthesizer.

    It is also a spring-mass synth but with Midi and audio and much more options.

    https://anukari.com/

  • Post Author
    mediumsmart
    Posted March 16, 2025 at 5:42 am

    Please plonk a { color: lightblue; } on the css.

Leave a comment

In the Shadows of Innovation”

© 2025 HackTech.info. All Rights Reserved.

Sign Up to Our Newsletter

Be the first to know the latest updates

Whoops, you're not connected to Mailchimp. You need to enter a valid Mailchimp API key.