Text Label That Displays Note Value

I have a drone player that I created that plays a note when a pad of my keyboard is played. I have a midi input in GP that sends the notes to a pad in Omnisphere. Is there a way in a text label to show that note value when played and have it continue to show that value until I change it?

This may help you

Oh, I was hoping to not get into scripting. I’ll take a look. Thanks!

Here’s a small script you can use and adapt however you need.
In this example I’ve set the handle for the MIDI In block as M1, and the handle for the text widget as label

Var
   M1 : MidiInBlock
   label : Widget
   a : integer

On NoteOnEvent(m : NoteMessage) from M1
a = GetNoteNumber(m)
SetWidgetLabel(label,NoteNumberToNoteName(a))
End
2 Likes

It is impossible for Gig Performer (or indeed any product) to do absolutely everything. That’s one of the reasons GP Script is available, to allow specific enhancements to added afterwards.

Much better than just saying, “sorry we can’t do that” :slight_smile:

No, I appreciate that. I was just hoping for simpler solution. It’s all good. I’ll figure it out.

Ok, I pasted your script into the Global Rackspace Editor (where I have the drone running), I changed the handle to M1, went to advanced for the widget and changed handle (GPScripName to label), turned on “show value in caption”, compiled the script without any errors and it doesn’t seem to work. Any thoughts on something I may have missed?

Did you make sure the “Use in GP Script” was selected for the MIDI block?

Also, don’t select “show value in caption”. The script does all the work.

label

Yes, I believe everything is setup correctly. I also just disabled, the “value in caption” setting. Not getting your results.



and you’re using a Text Label widget?

ScreenHunter 102

Yes.

See if this gig file works for you.
I have the MIDI block and widget in the Global rackspace, just as you do.

label_test.gig (29.6 KB)

It works and it also seems to match what I have

Well, at least you know that it will work.
You’ll have to root out the difference and remedy it.
When in doubt, start over.

Sounds good. I’ll give it a shot

1 Like

I copied your widget and input into my gig and it still didn’t work. Everything is identical. Very strange.

Did you recompile the script?

Yes I did.

and the MIDI In block is the one connected to the controller you are using to test this?
You can upload a smaller version of your gig file and I’ll look at it.

drone label test.gig (635.4 KB)