_______               __                   _______
       |   |   |.---.-..----.|  |--..-----..----. |    |  |.-----..--.--.--..-----.
       |       ||  _  ||  __||    < |  -__||   _| |       ||  -__||  |  |  ||__ --|
       |___|___||___._||____||__|__||_____||__|   |__|____||_____||________||_____|
                                                             on Gopher (inofficial)
   URI Visit Hacker News on the Web
       
       
       COMMENT PAGE FOR:
   URI   Show HN: What if your synthesizer was powered by APL (or a dumb K clone)?
       
       
        UncleEntity wrote 2 hours 31 min ago:
        > ...and the right-to-left evaluation logic.
        
        The evaluation order doesn't matter as much as you don't really know
        what kind of function/operator you have at parse time so have to do a
        bunch of shenanigans to defer that decision until runtime while still
        keeping it efficient. Kind of fiddly to get right but once it works, it
        just works.
        
        Claude and me (and a ton of decades old research) pretty much figured
        out all the complications in the APL parse/eval stack ( [1] ).
        
   URI  [1]: https://github.com/dan-eicher/AiPL
       
          octetta wrote 2 hours 17 min ago:
          I'm looking forward to checking out your stuff...
       
        octetta wrote 2 hours 36 min ago:
        A warning... if you save a setup to JSON, it naively stores the
        generated waveforms put in slots and the notebook, so the files can
        become quiet large. I have a plan to just keep the code behind the
        waves and regenerate the waveforms at load time.
       
        octetta wrote 2 hours 44 min ago:
        On the C-side, I'm going to add a UDP listener to the code so I can
        send k-synth incantations live from Emacs (something I did for my skred
        program at the suggestion of an Emacs user).
        Let me know if anyone wants to know about this when it's usable.
        On the desktop app side, I use miniaudio (thank's Macron) so this is
        portable to the usual suspects.
        I also made a single header file cross platform midi library which I
        have some devious plans for in this space. Stay tuned.
       
        jdontillman wrote 3 hours 42 min ago:
        See also: Stanley Jordan, "APL For Music". [1] (!!!)
        
        (Wait, what?  That Stanley Jordan?)  (Yep.)
        
   URI  [1]: https://dl.acm.org/doi/pdf/10.1145/75144.75174
       
          octetta wrote 3 hours 28 min ago:
          Wow! I had no idea, will look here for inspiration too. Thanks!
       
        jodrellblank wrote 4 hours 24 min ago:
        Marshall Lochbaum's APL-derived language BQN has some nods towards
        audio synthesis too:
        
   URI  [1]: https://mlochbaum.github.io/BQN-Musician/synth/index.html
       
          bradrn wrote 3 hours 16 min ago:
          Also Uiua: [1]
          
   URI    [1]: https://www.uiua.org/tour#audio
   URI    [2]: https://www.uiua.org/tutorial/audio
       
            octetta wrote 3 hours 9 min ago:
            Wowie! I'M NOT WORTHY! Cool stuff!
       
              bradrn wrote 3 hours 5 min ago:
              It’s not my language, to be clear! In fact I’ve never even
              tried it… my array programming experience so far has mostly
              been with J.
       
                octetta wrote 3 hours 2 min ago:
                Doesn't matter. Just happy people are doing weird stuff like
                this and appreciate the share.
                I looked at a bunch of APL-ish implementations and kind of ran
                with the K-simple code (links on the repo).
                What background do you come to J from? Another programming
                language? How do you like it?
       
                  bradrn wrote 2 hours 44 min ago:
                  > What background do you come to J from? Another programming
                  language?
                  
                  Yes, I’m very fond of trying out different languages. My
                  main language for personal projects is Haskell.
                  
                  > How do you like it?
                  
                  I haven’t used J for a while, actually, but I recall
                  finding it a bit confusing, especially when rank manipuations
                  are involved. It has a larger vocabulary than most array
                  languages, which I felt made it hard to learn. It was great
                  fun though!
       
                    octetta wrote 2 hours 19 min ago:
                    Fun. I've lost count of the languages I've learned and
                    gotten paid to use over the years, but it's mostly very
                    exciting to add a new one to the list.
                    
                    Haskell is one I haven't used yet. The closest I've come to
                    that is a weekend fling with OCaml... much respect for the
                    ML work though!
                    
                    I hear you for the complexities in J though. I've
                    intentionally limited k-synth to single letter upper case
                    variables and the verbs are also one character... I might
                    regret this at some point.
                    
                    Have fun! It makes the world a better place!
       
          octetta wrote 4 hours 18 min ago:
          BQN kicks-ass and I've spent hours listening to the Array Cast
          podcast while in SoCal traffic. I'll check his stuff out with an eye
          towards the audio stuff.
          
          I'm an APL newb... while I've been writing code-for-cash forever (C,
          etc.) I've had a long-time interest in APL languages, but I'm just
          messing around after working on waveform generation for another sound
          project I have in the works ( [1] ... [2] ).
          
          While I was working on this I remember the first book I saw in the
          public library on computer programming was about APL (probably
          sometime around 1976)... I didn't have access to a "real computer"
          for another year after that and no APL for decades, but some ideas
          stick around, LOL.
          
   URI    [1]: https://github.com/octetta/skred
   URI    [2]: https://youtu.be/L5-3gBpJsAo?si=JdBlntzn4doY-c3s
       
        octetta wrote 5 hours 4 min ago:
        I have a CLI and desktop versions on github (all MIT license) [1] [2]
        it's been a blast to play with... and a great excuse to learn array
        languages
        
   URI  [1]: https://github.com/octetta/k-synth
   URI  [2]: https://github.com/octetta/ksynth-desktop/
       
        jart wrote 5 hours 12 min ago:
        How do we get it to play Kompressor?
        
   URI  [1]: https://youtu.be/9tlA0IyKjiI
       
          octetta wrote 5 hours 3 min ago:
          Wowie... Jart commented! I'm on it my friend. Certainly sequencing is
          a good thing to add.
       
        steveBK123 wrote 5 hours 17 min ago:
        This is great
       
          octetta wrote 5 hours 17 min ago:
          thanks!
       
        hmokiguess wrote 5 hours 25 min ago:
        Pretty cool, one suggestion for the site would be to have templates you
        can quickly load, copy, edit, and share. Sort of like strudel.cc has!
       
          octetta wrote 4 hours 0 min ago:
          At any rate, in case it's hard to see, definitely try loading the
          dm-bell.ks patch, putting it in slot one so the melodic pad can play
          it... it's quick and dirty to see what's capable in a few
          keystrokes... although I'm sure the PD and ChucK and SC and ...
          wizards could put me to shame in a showdown, LOL.
       
          octetta wrote 5 hours 17 min ago:
          i wimped out and just have the patches being loaded from my github
          repo. good suggestion though.
       
            xrd wrote 4 hours 25 min ago:
            Did you know you can embed strudel?
            
   URI      [1]: https://strudel.cc/technical-manual/project-start/
       
              octetta wrote 4 hours 4 min ago:
              Strudel (and PureData, and ChucK, and SuperCollider, and AMY) are
              all great projects, but they weren't scratching my itch, so after
              I got laid off from a FAANG role, I rage/anxiety started writing
              code for stuff fun-ner than writing code for radios and routers
              and satellites... this is where my cortisol / dopamine lead me.
              No disrespect to those other projects... all have been
              inspirational and are a heck of a lot more "respectable" than my
              playground code.
       
              hmokiguess wrote 4 hours 11 min ago:
              I don’t think this is relevant to my analogy there, what were
              you thinking here?
       
                xrd wrote 3 hours 31 min ago:
                You are right but I wondered if octetta had considered
                combining his ui with strudel. I am fascinated by it and have
                been attempting to riff off it and create new creative
                interfaces.
       
                  octetta wrote 3 hours 24 min ago:
                  I'll take a look... it's probably not obvious, but the
                  language engine is actually written in C and emscripten-ed to
                  WASM, so I've already crossed several bridges to get this
                  done.
                  Absolutely riff off this interface... would love to see what
                  you can make. My stuff is MIT licensed, so tear it up!
                  On a side note, I was able to meet Sam Aaron of SonicPi /
                  Tau5 at Goarmire back in September which was cool... he
                  teased us with Super Collider in JS then and since, he's
                  crossed the finish line on that stuff.
                  We live in amazing times! Have fun!!!
       
       
   DIR <- back to front page