Forum

    • Register
    • Login
    • Search
    • Categories

    sampler methods in docs throw error "function not found"

    Scripting Forum
    2
    3
    80
    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.
    • P
      pnyboer last edited by

      I'm trying to learn more about scripting a Sampler. I've been going through the docs and have been getting several errors with some of the selection methods.
      https://docs.hise.audio/scripting/scripting-api/sampler/index.html

      I tried to create a basic selection with

      const var MPOneShot = Synth.getSampler("MP One Shot");
      var select = MPOneShot.selectSounds("Clap Broken_40.wav");
      MPOneShot.createListFromScriptSelection();
      

      but it throws a function not found error in the console for the createListFromScriptSelection.
      I have a similar issue with the createSelection method.

      Ultimately I'm trying to create an array of the names of samples in the Sample Map, I was hoping this would take me in the right direction!

      http://sensel.com/morph

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

        Try Sampler.createListFromScriptSelection();

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

        1 Reply Last reply Reply Quote 0
        • P
          pnyboer last edited by

          Within a Sampler's MIDI Script processor in onInit, I tried the simplest thing I could think of for this:

          Sampler.selectSounds("_");
          Sampler.createListFromScriptSelection();
          

          throws
          constant not found: Sampler.createListFromScriptSelection {U2NyaXB0IFByb2Nlc3NvcjJ8fDk1fDN8Mzg=} Script Processor2:! Line 3, column 38: Function / constant not found: Sampler.createListFromScriptSelection

          http://sensel.com/morph

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

          21
          Online

          1.1k
          Users

          6.8k
          Topics

          62.4k
          Posts