Requesting help on script from Youtube Vid with Thaddaus

Well now I’m confused as I just pasted what edm11 offered above and since David seemed to question the use of MOSC earlier, I thought maybe it was extraneous. I’ll fix that when I get back from tonight’s gig. Thanks everyone for the help. Not trying to be a dim bulb, but I’m swimming in new waters here. Give me a month and I MIGHT have a clue.

Sigh — I questioned the use of MOSC earlier because in your earlier post you declared that variable as just OSC

In your more recent example, you have the variable declared as MOSC which is why I made that comment.

I would encourage you to take a look at the language documentation and build some simple script programs to become familiar with how this language works. For example, you cannot refer to a variable that you have not previously declared.

1 Like

I’m sorry this is a sigh worthy post on my part. I have attempted to read the GP scripting documentation but I have to admit, given my complete lack of background, it’s all greek to me. Please understand how I got here: I asked in the general forum how I could solve an audio file player issue and someone said to try a different instance. Then I asked how to make those changes to songs across those instances and was given a link to a video and told “it’ll show you in there”. That video referenced a “simple” script but there was no copy of said script available, just a fuzzy screenshot. So I attempted to recreate the script from said screenshot. When I got errors, and after about half an hour of trying to decipher my errors, I came here. On this very thread, I have had several comments to fix it by changing MOSC to OSC and vice versa. After reading list of functions I am more confused then ever. I cannot even find mention of MOSC in the documentation at all. I have no idea how that differs from OSC. Again, I was attempting to recreate this script from a screenshot off of a youtube video.

It might just be a situation where if one doesn’t have some background in computer programming, GP scripting/OSC Scripting may just not be in the cards for the average user. I guess I was just hopeful there might be one written already for this.

Is it possible for one you veterans to maybe just identify where my script differs from the one that was working on the youtube video? It must be obvious to those of you that know what you are doing. I’m just lost and trying to find my way to playing tracks along with songs where I switch rackspaces mid-song.

Ok, you have 2 instances and want to sync the songs in the 2nd instance when you switch a song in the 1st instance?

Take this

var CurrentSong : String
    MOSC        : OSCMessage
    
// Called when you switch to another song
On Song(oldSongIndex : integer, newSongIndex : integer)
    CurrentSong = GetCurrentSongName()
    OSC_SetAddress(MOSC, "/GigPerformer/SwitchToSong")
    OSC_ClearArgs(MOSC)
    OSC_AppendStringArg(MOSC, CurrentSong)
    OSC_SendSpecific(MOSC, OSC_GetIPAddressFromTargetName("GP Bass"),
                           OSC_GetPortNumberFromTargetName("GP Bass"))
End

Yes, that is my goal. 2 instances with exactly the same songlists and just have changes to the master reflect on the slave (is that the term here?) The script I posted seemed to work in the video for Thaddaus. I think it was obviously complicated by his use of Target lists and maybe it would be simpler to eliminate those? I am flexible and will work it any way you suggest.

Thanks so much. I’ll try that in just a bit.

I understand the sync, but why sync all widget changes?
This way you have to put all widget to controls VST Parameters in the Master Gig
And is it really needed?
When I make sound changes, I do that in the VST plugin.
Only for sound parameters which need to be changed while playing I create Widgets.

Keep in mind only the song switcher synchronized, the Song part changes are not treated.

Hmm, I’m not sure I understand your question. Are you asking this question based on the previous script attempt above? Because I was just copying that from Thaddaus’ youtube video screenshot. I would definitely prefer NOT to have widgets to VST parameters affected. I would simply like to move song to song upon my song changes (not song parts as that’s where I switch rackspaces mid song).

Just simply advancing song to song is all I would like to do.

Sorry and thanks.

You can test with with gig file
OSCSwitchSong.gig (14.3 KB)

With this Songs and Song Parts are synced

var CurrentSong     : String
    CurrentSongPart : String
    MOSC            : OSCMessage
    
// Called when you switch to another song
On Song(oldSongIndex : integer, newSongIndex : integer)
    CurrentSong = GetCurrentSongName()
    OSC_SetAddress(MOSC, "/GigPerformer/SwitchToSong")
    OSC_ClearArgs(MOSC)
    OSC_AppendStringArg(MOSC, CurrentSong)
    OSC_SendSpecific(MOSC, OSC_GetIPAddressFromTargetName("GP Bass"),
                           OSC_GetPortNumberFromTargetName("GP Bass"))
End

// Called when you switch to another songpart
On Songpart(oldSongpartIndex : integer, newSongpartIndex : integer)
   CurrentSongPart = GetCurrentSongPartName()
   OSC_SetAddress(MOSC, "/Song/SwitchToPart")
   OSC_ClearArgs(MOSC)
   OSC_AppendStringArg(MOSC, CurrentSongPart)
   OSC_SendSpecific(MOSC, OSC_GetIPAddressFromTargetName("GP Bass"),
                          OSC_GetPortNumberFromTargetName("GP Bass"))
End

Wait, if I just want an audio file player to run in instance 2, don’t I just need song switches and not part switches? Won’t a song part switch interrupt file playback?

It depends what you are referencing in Song Part.
Each Song Part can reference a different rackspace variation and so you could reference different rackspaces in 1 song.
As long as you only reference variations from the same rackspace there is no issue with Audio File Player.
You should read the user manual, where all this is clearly documented.

Keep in mind: Gig Performer is so flexible, it can do all what you want, but when you are not aware of the design philosophy you can make things total over complicated.

Yeah, I’m still learning this and I’ve read most of the documentation but that doesn’t mean I understand it all yet. It usually takes me encountering each aspect “in the wild” to get the concepts. As you mentioned, the sophistication makes understanding the design philosophy complicated. There are simply so many ways to skin the cat, I often just use the first one that works (to then find out later, there is a better way).

Thanks so much for your help. I had a busy gig weekend so just now getting my gig-rig loaded into the office here so I can fire up the machine and start integrating.

So the script compiled without incident (thanks so much) but I’m still not getting it to change songs. Here is my OSC setup (for some reason, my IP address went from 127.0.0.1 to that 192.168.1.15 and I don’t know why, but I replicated it throughout). Am I doing something wrong here:

You enabled WLAN, right?

How looks your OSC Targets?
Press the Button “Manage OSC Targets” in the 1st instance.
And set the Remote client port to 9002 in the 2nd instance - to avoid feedback loops, to be sure

And maybe a stupid question:
The song names and song part names in the 1st and 2nd instance are the same?
Did you try with the example gig file I uploaded?

Please show the content of the Gig Script window.

Okay, that remote client port to 9002 fixed it I think.

I’m in business! Thanks so much for your help. First time is always the hardest!

1 Like

Morning all,

So I’ve been digging a bit deeper into the documentation and trying to get a handle on things but the combination of comprehending both GP script and OSC messages all at once means my learning curve will be long. That being said, I’ve also seen that using this functionality isn’t really intended for those without some basic understanding of coding, which now makes total sense. However, I am a working “weekend warrior” in a few bands and I need to keep progress going forward on GP as it’s my chosen replacement for the eventual Kronos Retirement. That being the case, I am wondering if anyone who might read this thread might be available for some “contract script writing” work until I have seen/read enough on the subject to start writing my own. I’ll gladly pay for scripts to get me past “sticking points” in my planned rollout in GP. I recognize that this community is probably largely made of up folks with little spare time, but maybe there’s someone who could use some extra drinking money from time to time?

Please PM me if interested, or you can reply her to laugh at me. lol. I just don’t want to waste the whole community’s time with my intro level BS. (I will figure it out as I see more content however; it’s just greek to me atm).

Thanks in advance,

You might want to provide a concise description of what exactly you’re trying to accomplish — in your earlier posts you’ve asked for help for specific problems but it’s unclear exactly what you want to actually do generally that requires all this scripting and OSC