Soundradix Mutematic “over ride” script
Hello!
Christian suggested I create a new thread here for a soundflow solution that I think many could benefit from.
I’m looking for script/ trigger for the free Sound Radix Mutematic plugin.
This talkback plugin opens / closes the inserted channel based on a sessions playback status.
But can be overridden by pressing the “state” gui button.
The script I’m looking for would “press” the GUI “state” button, and that script could be mapped to some tactile source.
This new trigger/ button will essentially act as a push to talk switch.
Thanks in advance for your time and interest.
Stoked to find out if this is a doable thing or not.
All the best,
Sean
- Ddanielkassulke @danielkassulke
Hi Sean,
I've actually created a script to do this without a plugin. It's a talkback mute toggle, but it sounds like it could easily be tweaked for your needs. All artist talkback channels have the prefix "TB", so this acts on every channel with "TB" in the name. I just have to ensure those TB channels are initially muted, because the toggle toggles the mute and input monitoring state simultaneously.
sf.ui.proTools.appActivateMainWindow(); sf.ui.proTools.invalidate(); function toggleInput(trackName) { var track = sf.ui.proTools.trackGetByName({ name: trackName, makeVisible: true, }).track; var inputBtn = track.buttons.whoseTitle.is('TrackInput Monitor').first; // Check if the track is muted if (track.isMuted) { // Enable input monitoring inputBtn.elementClick(); // Disable mute state track.trackSetMute({ targetValue: "Disable", }); } else { // Disable input monitoring inputBtn.elementClick(); // Enable mute state track.trackSetMute({ targetValue: "Enable", }); } } function toggleInputContaining(partialTrackName) { var matchingTrackNames = sf.ui.proTools.trackNames.filter(n => n.toLowerCase().indexOf(partialTrackName.toLowerCase()) >= 0); matchingTrackNames.map(toggleInput); } toggleInputContaining('TB');
- SIn reply toSean_McDonald5⬆:Sean McDonald @Sean_McDonald5
thanks for the reply!
heres the features im looking for [with or without the mutematic plug]
-
TB channel automatically opens when parked.
-
TB automatically closes during playback.
-
physical key/ button to override either open or closed auto status of TB channel
do you think your script could make this happen?
thanks!
Sean -
- DIn reply toSean_McDonald5⬆:danielkassulke @danielkassulke
Hi Sean,
I think there is definitely a way to make this happen. My instinct would be that you need two scripts: one that assesses the playback state and enables input monitoring when playback is stopped. Then use an application trigger so it's only acting when protools is active. The second script would do the opposite; disables input monitoring during playback. My script does the third already. I had a bash at a script more closely matching your requirements, but it was buggy. I'll keep chipping away to see if I can get it up to scratch before I try posting it here. From what I've read on this forum, those scripts that are always running are potentially problematic, but there might be a more experienced user who has a neater solution for this kind of thing.
- SSean McDonald @Sean_McDonald5
Hey,
Thanks sooooooo much for the interest and the offer of assistance.Much appreciated 👍👍👍👍
- Ddanielkassulke @danielkassulke
This is working so far. Note that you'll have to change line 35 to suit your preferred talkback track naming convention. I use 'TB'. If you initially enable input monitoring while playback is paused, it should reliably work without manual intervention from then onwards.
sf.ui.proTools.appActivateMainWindow(); sf.ui.proTools.invalidate(); function setTrackState(trackName, enableInputMonitoring) { const track = sf.ui.proTools.trackGetByName({ name: trackName, makeVisible: true, }).track; const inputBtn = track.buttons.whoseTitle.is('TrackInput Monitor').first; if (inputBtn.value !== enableInputMonitoring) { inputBtn.elementClick(); } } function setTracksStateForTracksContaining(partialTrackName, enableInputMonitoring) { const matchingTrackNames = sf.ui.proTools.trackNames.filter(n => n.toLowerCase().includes(partialTrackName.toLowerCase())); matchingTrackNames.forEach(function(trackName) { setTrackState(trackName, enableInputMonitoring); }); } function monitorProTools() { sf.ui.proTools.appActivateMainWindow(); sf.ui.proTools.mainWindow.invalidate(); let lastIsPlayingValue = null; while (true) { const isPlaying = sf.ui.proTools.isPlaying; if (isPlaying !== lastIsPlayingValue) { // If Pro Tools is playing, disable input monitoring for tracks containing 'TB' setTracksStateForTracksContaining('TB', !isPlaying); lastIsPlayingValue = isPlaying; } sf.wait({ intervalMs: 500 }); } } monitorProTools();
- Ddanielkassulke @danielkassulke
This actually seems to make other soundflow commands run unreliably as this script is always running. Not sure how this could be avoided.
- SIn reply toSean_McDonald5⬆:Sean McDonald @Sean_McDonald5
Thanks for the update, AND the effort/ leg work.
Much appreciated.I’m wondering, if the solution would need to include 2 talkback channels to cover the auto start /stop (mute/ open) as well as the push to talk override feature?
TB Channel 1:
Mic feeding aux with sound radix mutematic plugin inserted.
Opening channel when parked.
Close channel when rolling.TB channel 2:
This is with the current, working soundflow script that opens / closes that talkback channel with a push of a mapped key/ button.
Fed by same talkback mic and input.The thought is, can you add a script to TB channel 2’s current code, to ALSO mute or bypass TB channel 1 when Channel
2 is being used?So we get an “either or” type of performance between the two channels.
A division of labor.Hopefully that made sense🙂
And thanks once again for the interest and expertise.
Best,
Sean- Ddanielkassulke @danielkassulke
Sorry for the sluggish reply, Sean. The current issue is that for soundflow to be perpetually evaluating its playback state, other commands executed will either not work, or not work consistently. I wouldn't say my attempts to squirrel code from other areas of the forum is expertise, but I have read that @chrscheuer was weighing up the possibility of implementing a specific talkback feature within a future soundflow release. I'm wary of spamming the soundflow team, but I think for this to work in the background as effectively as we would both need while letting soundflow run other tasks, it's a bit beyond my skillset or current understanding. For now though, the initial script I posted seems to be bullet proof in my use in 2023.9, and the only drawback is (as with any comms switch) remembering to hit the talkback button. It's super convenient if you have a streamdeck / surface.
- SSean McDonald @Sean_McDonald5
thanks!
sorry for MY sluggish response.Hopefully you are correct, and there will be some TB solution in future builds.
thanks again.
Best,
Sean