HISE Logo Forum
    • Categories
    • Register
    • Login

    Generative Wavetable OSC?

    Scheduled Pinned Locked Moved General Questions
    14 Posts 6 Posters 260 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • StraticahS
      Straticah
      last edited by

      Hey there i want to create a wavetable oscillator for the HISE synth group that allows for drawing a custom wavetable by hand or generating a "random" one.

      Whats the best way to approach this? SNEX, RNBO, FAUST...

      building user interfaces in HISE :)
      web: www.vst-design.com

      HISEnbergH 1 Reply Last reply Reply Quote 1
      • HISEnbergH
        HISEnberg @Straticah
        last edited by

        @Straticah Sounds like you would need a custom C++ node to do this.

        StraticahS griffinboyG 3 Replies Last reply Reply Quote 0
        • StraticahS
          Straticah @HISEnberg
          last edited by Straticah

          @HISEnberg oh no! so no way i could do it utilizing SNEX, RNBO, FAUST? I guess if i use snex i need to go c++ anyways

          I will start checking SNEX synth examples :)

          building user interfaces in HISE :)
          web: www.vst-design.com

          1 Reply Last reply Reply Quote 0
          • StraticahS
            Straticah @HISEnberg
            last edited by

            @HISEnberg i am already running into issues with snex osc - seems it does not support variable-length arrays, not even fixed-size arrays?

            building user interfaces in HISE :)
            web: www.vst-design.com

            HISEnbergH 1 Reply Last reply Reply Quote 0
            • HISEnbergH
              HISEnberg @Straticah
              last edited by

              @Straticah I think it should but I really know little to nothing about SNEX..

              With RNBO you can import buffers and possibly use a sliderpack or table to edit them, so this seems like the lowest resistance option for you.

              1 Reply Last reply Reply Quote 0
              • griffinboyG
                griffinboy @HISEnberg
                last edited by

                @HISEnberg
                @Straticah

                Honestly one of the hard things here is how to get the 'drawn' information into the node. Christoph is working on new ways to communicate complex info into custom nodes but it's not here yet.

                C++ is probably the way to go though. Especially since you'll need to implement algorithms to interpret that shape into something that doesn't generate a ton of aliasing. You'll need antialias, which will end up being a bigger more complex script. C++ will allow you to organise better using headers and external libraries.

                Not that you can't do it in snex. But it's probably worth doing it in c++ for the workflow more than anything else. And for the fact that there are lots of C++ libraries and github repositories for this kind of thing that you can use as reference or straight up plug in.

                1 Reply Last reply Reply Quote 2
                • A
                  aaronventure
                  last edited by aaronventure

                  I think you should be able to use a panel for the UI to allow drawing (storing event.y data for each event.x) and use that to fill a table. Then just plug a looping ramp into the table in ScriptNode and there's your drawn oscillator.

                  As a bonus, you can apply smoothing to the signal, but you'll have to do it in a modchain because the direct signal smoother node only works on one channel, until it gets fixed.

                  StraticahS 1 Reply Last reply Reply Quote 2
                  • D
                    dianasv25
                    last edited by

                    You want a wavetable oscillator where:

                    Hand-Drawn Wavetables: Users can draw a waveform (e.g., via a UI element) to define a single-cycle waveform.
                    Random Generation: A function generates a random single-cycle waveform.
                    HISE Integration: The oscillator works within HISE, leveraging its synthesis and modulation capabilities.
                    HISE already has a built-in WavetableSynth module, but it relies on pre-converted .hwt files and doesn’t natively support real-time drawing or random generation in its UI. You’ll need to create a custom oscillator and possibly extend the UI to meet your needs.

                    HISE supports multiple DSP development paths:

                    SNEX: A C++-like scripting language native to HISE for real-time DSP, integrated with its scriptnode system.
                    RNBO: A Max/MSP-based code export tool from Cycling ’74, which generates C++ code deployable in HISE.
                    FAUST: A functional programming language for signal processing, which compiles to C++ and can be integrated into HISE.

                    StraticahS 1 Reply Last reply Reply Quote 0
                    • StraticahS
                      Straticah @dianasv25
                      last edited by

                      @dianasv25 this ai?

                      building user interfaces in HISE :)
                      web: www.vst-design.com

                      1 Reply Last reply Reply Quote 2
                      • StraticahS
                        Straticah @aaronventure
                        last edited by Straticah

                        @aaronventure thanks will check!

                        @griffinboy what does something like this cost freelance properly setup?

                        I will probably go another route and combine some basic shapes into a wavetable and not generate the table from scratch.

                        building user interfaces in HISE :)
                        web: www.vst-design.com

                        griffinboyG 1 Reply Last reply Reply Quote 0
                        • griffinboyG
                          griffinboy @Straticah
                          last edited by griffinboy

                          @Straticah

                          Cost? I wouldn't be sure! Personally I'd be able to do it myself fairly easily. The hard part is interfacing with the rest of Hise. I've never done that kind of data communication before to an external node. Like @aaronventure said, using a table would probably be the way, for c++ you can communicate table data to c++ nodes from Hise.

                          If I were to guess, the whole thing would probably take a few days to a week maximum. But I don't know how much that would cost freelance.

                          edit* I was wrong, Christoph has implemented communication to c++ nodes for different data types now. So communication shouldn't be an issue

                          1 Reply Last reply Reply Quote 1
                          • A
                            Allen
                            last edited by

                            RNBO is also a nice way to go.

                            I think you mean wave terrain synthesis for the "random" generated wavetable. It usually implemented by reading the data in a certain area of a dynamic 2d matrix(like a glsl), scale the data size into one cycle length of the wavetable and play it back.

                            There's a book called "generating sound & organizing time" which has nice examples of wavetable and wave terrain oscillators made in gen~, which can be your start point.

                            for the drawing case, I think you just need to add a multislider with the size of one cycle and write the data in multislider into the wavetable buffer with an offset of "cycle length * cycle index"

                            HISEnbergH 1 Reply Last reply Reply Quote 2
                            • HISEnbergH
                              HISEnberg @Allen
                              last edited by

                              @Allen oh true, the GOT book is a really good recommendation for navigating wavetables in max, and you can bring a lot of this into RNBO and Hise

                              1 Reply Last reply Reply Quote 0
                              • A
                                aaronventure
                                last edited by

                                Nice little practice....

                                086de2fa-536d-4bd3-9eae-774dc04206b9-image.png

                                HiseSnippet 4354.3oc0aszbiakcFTpQaKY2YFWyLUkkHJUMCUfLMAeAfxSmVuaIqWrEYqGcWc0CHvkjnEH.Z.PIQE6UYyrKqSVkE4GP1lc9OvrZ9Ujc9ePx4buW.BHBvtGEaWYnKKyyEm64dNemuy4BPbc6.OSRXnWfPok6NwmHT5yE6LwMZ3VCMrcE1eagR+MhGYDFQBjXCs4DeivPhkPoRK9bbfRK8HA5me3YaZ3X3ZRlNjfvYd1ljCsGYGMcz1qefsiytFVjt1iRoci022zycKOGuwf+rnXUAeCyqLFPN1.UaAQg8LBGJT5ePrkUeiVVpMqpPpqYoVSQsodC0VUq12RSQsmZu5FVFsTqJT5w6XYG4EzIxHhDJT5Qa5YMoyPuabYKvY1g18bHnfhPGXkYCuqmiEFh3nBaMz1wpcLPEJ.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2cOivtF1NHOuy3PeveNwsCnL8vPVZwyvW9GZ3OQrZE3e.d+wdVvkd7tFl.vNosA1a4KDw22CvVIA3a8jyZy3qYHNzSEYlKiVM97SJF2vaDsc2BhPVIUOYFmEkfJxEXKz9gmgW0zvQ3L16DBhNzlLHj4xryDZ+.X0u8sT1mPln3uMUTjQqY886YleJ89ES48KKNxyhAvY77ecJOOQiY85TS+mAO9SXGZS9IgfDj0k+Uh7SJVkoJLqGmd5ywk+LwcCHueLvZmjbBXgljyOJdLtU.I1+WhZhZGAZNceftFACHQg76MvkXxpxn0.6agl.XA9BsMPx.3i3XetXaRfsmE8DBO8RLOHVBPmircOK6qurw5GYba1w9i+406DQ7wtj3X+a+q3m+qm04JxMLzDG8O8s+2p+yi9SOCCpOQjYfDyvtimtquMouwXmnyt+aLUHE8hGNYxSXFHfTgdgYyO7Y7AXSOJcd3u.38Ihl39Kukd6PYQ433jdeQNjaiuEtssC8gMZ1bLrCJCyyLBl5iusJrm6Nv1FV.cgN839vYxYKlJm8o2Km8ui4hYxYq+ujImEqW1bV785vJmRwXtWB5xBRbWt9FrS+B6dTDlOyB.866kvZeOuj9oXu7yDOzyyG1IMHRXFyWH65md+5wv8WFMCt8COKeW5GdVZBeVBVFd+uYZ+oTpLaEPVSLmBAMw7NgwRkU9xdF3YtEOQOvyjHwjrc4mU4Ue3kOhhFVVebkM76iK9aoKSvf3CWlTZNkI+Hknmo01Gh7UPERX1ldLTJStG1mDOad33ylvY5+A53sPlT1ekgTY1QXvL2rAeGgA4eOF7Y7vwmEmeKiK+9YwG.K9XZ398C9O+MqG2x.7wTVYc898+6+9e75h8wtGve3Ws8el2csyHOungvyXHLysEjue0Xcge5gpOW7TR7437gz1+9oWgM87tZjA8YadP+xK+r7jXiLLC7dKeC.jT9ozQ.xoKkjuj3Qnrjxrm.sQ1V1u0zLqolYh0dnSr9CchMdnSr4CchsdnST8gNQsO7Dw+WZi2sC2rDJcauCaWsR63ha8QakI7+BtlhzHC
                                

                                Tweak the res variable for input resolution. Basically it's "step size" in pixels.

                                You can put a smoother in the chain in ScriptNode to get some smoothing - probably a good idea, but you'll need to dynamically change the smoothing time to compensate for frequency changes, so use the core.smoother node until the cable one gets fixed.

                                Also, you could do some math for setting the Curve value of each point, so that the previous point's Curve is set based on the the current Y vs previous Y.

                                4290af26-195a-45ce-8393-ac9acb987752-image.png

                                If you want to allow the user to change the curve for each point manually, that can also be done with the mouse callback of the panel.

                                Then simply decide how you want to set the frequency:

                                • from script: create a parameter in the network and set it for each note on
                                • automatically/polyphonically: use this in a scriptnode synthesiser

                                If you're changing networks, you'll need to make sure the network reference is correct and that you set the cable_table node to an external slot using the little icon next to the table display in scriptnode.

                                1 Reply Last reply Reply Quote 3
                                • First post
                                  Last post

                                21

                                Online

                                1.7k

                                Users

                                11.8k

                                Topics

                                102.5k

                                Posts