HISE Logo Forum
    • Categories
    • Register
    • Login

    AudioWaveform and sampleIndex setting

    Scheduled Pinned Locked Moved General Questions
    6 Posts 3 Posters 286 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.
    • LindonL
      Lindon
      last edited by

      So I have an AudioWaveform in my UI (well I have more than one but hey - not important there) and I want to be able to display the sample being played by the last played note....

      So no problem setting the sampleIndex:

      MyAudioWaveform.set("sampleIndex",<somevalue here>);
      

      so I know what the note number is ...

      any ideas on how I match this up with the sampleIndex in the currently loaded Sampler??

      • cant see anything in Sampler API or waveForm API or here in the forums...but Im old and I've been known to miss stuff...

      HISE Development for hire.
      www.channelrobot.com

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

        If you set the index to -1 and connect it to the sampler via processor ID it will do what you want automatically.

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

          @d-healey thanks - it takes a little jiggery pokery to get this sorted : so setting = -1 means nothing is displayed in init or sample load... but easy fixable...

          HISE Development for hire.
          www.channelrobot.com

          d.healeyD DanHD 2 Replies Last reply Reply Quote 0
          • d.healeyD
            d.healey @Lindon
            last edited by

            This post is deleted!
            1 Reply Last reply Reply Quote 0
            • DanHD
              DanH @Lindon
              last edited by

              @Lindon I've been meaning to get around this for ages. What's your method?

              DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
              https://dhplugins.com/ | https://dcbreaks.com/
              London, UK

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

                @DanH so basically my sampleLoad function now sets the sampleIndex = 0, so we are always displaying something at least...

                and my onNote :

                if (SamplerSpace.AudioWaveform1.get("sampleIndex") != -1)
                 {
                	SamplerSpace.AudioWaveform1.set("sampleIndex", -1);
                };
                

                HISE Development for hire.
                www.channelrobot.com

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

                31

                Online

                1.7k

                Users

                11.8k

                Topics

                102.8k

                Posts