HISE Logo Forum
    • Categories
    • Register
    • Login

    Connect Waveform to Sampler with Scripting

    Scheduled Pinned Locked Moved General Questions
    waveformsamplersprocessor id
    16 Posts 6 Posters 937 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.
    • oskarshO
      oskarsh @d.healey
      last edited by oskarsh

      @d-healey I am building a drumpad and want to assign a FX chain to each Sample individually. Is there a simpler way? FX chain includes, simple gain, panning, send effects and the faust transposer.

      d.healeyD 1 Reply Last reply Reply Quote 0
      • d.healeyD
        d.healey @oskarsh
        last edited by

        @oskarsh In that case I think one sample per sampler is correct

        Libre Wave - Freedom respecting instruments and effects
        My Patreon - HISE tutorials
        YouTube Channel - Public HISE tutorials

        Christoph HartC 1 Reply Last reply Reply Quote 0
        • Christoph HartC
          Christoph Hart @d.healey
          last edited by

          I would use AudioLoopers (or even a custom scriptnode synthesiser with a file player) for this.

          1 Reply Last reply Reply Quote 2
          • oskarshO
            oskarsh
            last edited by

            @Christoph-Hart thanks!

            What is the best way to trigger a audio loop player when a specific key is pressed? By default it plays on every key.

            Should I use a midi channel filter for this?

            ustkU 2 Replies Last reply Reply Quote 0
            • ustkU
              ustk @oskarsh
              last edited by ustk

              @oskarsh Yes a MIDI channel filter or just create your own key filtering if you just want to filter keys in each Audio Loop Player
              A way to do it can be detecting the key in a general script and change its channel to route it to the player you want, where you previously placed a channel filter

              HiseSnippet 1080.3oc6X00iaSDEcbRlxlTXosTg3Q+.HkHUVEGJsHUU1ra9nJhlciVmV3spo1SRFs1yXFOdgHT+uwS7L+T5+.3N1NqcJdCAC6Vnr9gHO26bsO2OlywJSjBGZXnPhLpOcY.EY79X6kb0hdKHLNZTejwt3wjPEUZlX5vkAjvPpKxvn5SzFLpWCAW9e8ur+gDOB2gtxj954BlC8oLelJy5jteCyyaHwkNk4ma22u6HGAumvSDA3oJtMJf3bJYN8HhdaUvHiaLvkoDRaEQ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x6DaAxad7+Obc7X8ZSqyYnvs2qMxGzadgiitb+4P8o3X5ThX9hRDy8KQLeYIh4AkHlGVhX9pMFiVp+fHkvO4nHXXxf3+tKCiAbBLIGO0i9cPeKMoL
              
              1 Reply Last reply Reply Quote 0
              • d.healeyD
                d.healey
                last edited by d.healey

                Add one of these to each loop player. No need for channel filtering.

                Link Preview Image
                RhapsodyBoilerplate/modules/NoteRangeFilter.js at main

                RhapsodyBoilerplate - Boilerplate code used by Rhapsody.

                favicon

                Codeberg.org (codeberg.org)

                Libre Wave - Freedom respecting instruments and effects
                My Patreon - HISE tutorials
                YouTube Channel - Public HISE tutorials

                1 Reply Last reply Reply Quote 2
                • ustkU
                  ustk @oskarsh
                  last edited by

                  This post is deleted!
                  1 Reply Last reply Reply Quote 0
                  • oskarshO
                    oskarsh
                    last edited by

                    @d-healey @ustk Thanks!

                    I am using this code now to ignore all notes that are not meant for the audio loop player.

                    function onNoteOn()
                    {
                    	const ON_NOTE = 41;
                    
                    	local note = Message.getNoteNumber();
                    	if (note != ON_NOTE)
                    		Message.ignoreEvent(true);
                    }
                    
                    d.healeyD LindonL 2 Replies Last reply Reply Quote 1
                    • d.healeyD
                      d.healey @oskarsh
                      last edited by

                      @oskarsh Looks good but put the const in on init.

                      Libre Wave - Freedom respecting instruments and effects
                      My Patreon - HISE tutorials
                      YouTube Channel - Public HISE tutorials

                      1 Reply Last reply Reply Quote 1
                      • LindonL
                        Lindon @oskarsh
                        last edited by

                        @oskarsh ..and dont forget to do the same in the onNoteOff()

                        HISE Development for hire.
                        www.channelrobot.com

                        Christoph HartC 1 Reply Last reply Reply Quote 0
                        • Christoph HartC
                          Christoph Hart @Lindon
                          last edited by

                          And since this is running 16 times for each note event in the audio thread, it might make sense to further optimize this, remove the conditional and variable storage:

                          Message.ignoreEvent(Message.getNoteNumber() != ON_NOTE);
                          
                          ustkU 1 Reply Last reply Reply Quote 2
                          • ustkU
                            ustk @Christoph Hart
                            last edited by

                            @Christoph-Hart Clever!

                            1 Reply Last reply Reply Quote 0
                            • S
                              Sawer
                              last edited by

                              Hello everyone
                              I am also trying to connect 1 waveform with 1 sampler, but no result. It actually crashes just after some seconds.

                              I tried by connecting the Waveform to the sampler in the waveform properties, but nothing shows when I trigger the sample.

                              I also tried using scripting, but no result.

                              My goal is to create a simple sampler that offers the possibility to trigger different transient of the samples by dragging inside the waveform. Just like inside the Default Hise sample Editor.

                              Is this achievable with the waveform?
                              Which part of the implementation am I doing wrong?

                              HiseSnippet 1214.3oc4W0raaaDDdok2TKYm1lfbnWJ.gQO3.3DH433TzdHx1xNUn9GAI2jbKXM4HoElbWhkKssZP.5iTO2S4QJuAoyRRItTQ0vQ0Isnkm3L6LK+1uYmeXGkzChikJhS0SFEADmUn8FIzC2cHiKHsaQbtK8Eryg9RUXOAOJBzMH6LJhEGC9DGmJOyXmS0EIoOu6o6vBXBOnPEg7bI2CNfGx0EZ6z7m4AA6y7gS3gVVuYy1dRwtx.YBhoJz5jHl2YrAvQLiYKPIN2ZOetVp5oYZHl3r3NR+Q8FJuPjY+y4w7SC.iPCRObixTuuLv2fXy6jcGxC76L9rGSHNzNELQkLl3dzC497I5KXjuNcA2BOr4CmEJCuJkfWCa3U2Bdy.RNVPZwLHcGZOOEORWrhAOKSaKzfpOCocanjYKw4szcknAB8CCYmA6qPgINr1V0qut6F0qe+erehvSykBWo3HoFNVr18q85ZUq8lZtSuT+9ybMymQICB.0LW1DoUWkiqIRBOETq6dNKHAlXHd7Kyoz+ZN0Nj6kcpsLTJZK35iifb4Oj0I4TE91uztESyLAhbcncQfRyMPvoEbNdqNKrTk1BhOSKivKn6JCijByN3rhN+dTVfX+.ISyECNgiPkiQnuhZqpA4R6jlQEBsadA2WODO2NubABYHvGLTaj7KvaFPpMIWkb5fwIQUu0xK+Gu2rQbMDVn883SYsajq92Lp0vk5BiGCqTJwoE800bcWcBw01e0evc0UW2nrsvGtDEePiTQLuKPdwKjpyhwLY.WnOKHFp8FCzmPUzLp514T0ArSgfTNZIZ56kHGQSKx46ZZ.pgkGezcagwa2eBT.Vl4CRgvjWoeR.SWNi1TFKeA7JYozHSthHlqGYWla5z7Eudo4EUgl4kuqIbuCsCW6Mb13cgYfW7R7mZ7lWz71z852G7zEfcQ59u7JqPdiCkuMCJ2k1Sq.VHle0iEFgUkRwSMZtzMRernqcerNJ.y186w+UKydaycRP9RUV6u2L8SscnLQT5aki7tPDvzX32xmkZ1s6yTxjno85cOM8xxIJrOJRE1Kbr.PdWaeF2UIii6iGmz8J1doNIpAFtpPSW3bPEWV2QIgXrWHf.SgZGGSgzXvDq4dGxzJdopboek5mvRi2Xy8T4FSIuwTxOZJ4MmR9wSIu0TxOoPNiPOjEYtYXFtXpNMew0qSCtAcX3Q1xxc3Clr4YZJWhwxzIbdJtrFkYFCEbqOUyo7Ys.1e+5s2LiUUcLF6wMgp8Dmi4nnlr4daA8YIA5wZKWu3PoPFMTJ3dkyHva3CF.JarOyCz1ZMlPVn4dM6BA.KFrasc.W.LU4D8OJtnwG8HlyLd8MzL35ZJx49ei9jU9eeexqh59x7tjt3WWo+WdbdEZZccWSa3+ofZWYhYR9ws3nXevdXueOvta3BlNrYx0MxF.0CD9oBl4wyWrw3VmlEaLdQh23sBOa4umMOdEPXZcjN9W.1TNv9JcLNggARX6sOKnLj4ojuxK6W5LXcoTMHJEo+CeU5gFY2FjzeyC8iV+g0IgXupW44YRDd.xvy1mMlCedzb3ylygOOdN7Yq4vmmLG978WoOlwD1NQKCyJRhJ5rW1EKm8lbwpB4OcLdHKE
                              
                              d.healeyD 1 Reply Last reply Reply Quote 0
                              • d.healeyD
                                d.healey @Sawer
                                last edited by

                                @Sawer You haven't set the processor ID

                                Libre Wave - Freedom respecting instruments and effects
                                My Patreon - HISE tutorials
                                YouTube Channel - Public HISE tutorials

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

                                23

                                Online

                                1.8k

                                Users

                                12.1k

                                Topics

                                105.1k

                                Posts