HISE Logo Forum
    • Categories
    • Register
    • Login

    Interface Keyboard Color in condition to played chord / midinotes

    Scheduled Pinned Locked Moved General Questions
    3 Posts 2 Posters 180 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.
    • M
      MidiOut
      last edited by MidiOut

      Hey there, i was inspired by @d-healey Youtubevideo on custom Keyboard Color and wanted to build something, that displays the currently played notes on the keyboard in the interface. Again it´s working inside HISE, but not when exported to Midi FX AU and used in Logic.

      Here´s my Interface onNoteOn function:

      function onNoteOn()
      {
      
      	
      
      for (i = 0; i < 128; i++)
      
      {
      	if (chord.contains(i))
      	{
      		Engine.setKeyColour(i, Colours.withAlpha(Colours.blue, 0.4));
      	}
       }
      }
      

      Anyone any Idea, why it´s working inside HISE but not on the PluginInterface?

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

        @MidiOut

        try putting your code in the code formatter - its easier for us to read - its this button in the forum editor: </>

        what's "chord"? some sort of array of held notes? why not just use:

        Synth.isKeyDown(int noteNumber)

        HISE Development for hire.
        www.channelrobot.com

        M 1 Reply Last reply Reply Quote 0
        • M
          MidiOut @Lindon
          last edited by

          @Lindon

          Hey Lindon, sorry, for the wrong format, and thanks for your tip! i´m new to this =) sat a lot of hours yesterday to figure this small piece of code out. :D

          We build some kind of chord trigger, that get´s chord arrays from atm a json.

          So you have around 8-10 chords in one set, that are mapped onto the keys. everything still pretty raw.

          I defined a global var in the scriptprocessor, that holds the currently played "artificial" notes to get the current mapped notes into the interfacescript. Thats "chord".

          The script is doing what i intended inside the HISE Environment but not after exporting.

          That so far.

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

          20

          Online

          1.7k

          Users

          11.9k

          Topics

          103.6k

          Posts