Hi forum,
I'm writing in order to know if it is possible to create a shortcut to show automation line of insert number 1.
Example: "Reduction" automation line of RX Voice De-Noise, in slot number 1 of insert
Thanks for your attention,
Best regards
Tomás Frias
- samuel henriques @samuel_henriques
Coméquié @Tomas_Frias,
Try this, it will do it for all selected tracks:
function showAutomationLanes() { //If any automation lane for selected tracks are hidden, show them. const showAutomationLaneBtn = sf.ui.proTools.selectedTrack.children.whoseTitle.is('Show/hide automation lanes').first; if (showAutomationLaneBtn.value.invalidate().value !== "Selected") { showAutomationLaneBtn.mouseClickElement({ isShift: true, isOption: true, }); } else { showAutomationLaneBtn.mouseClickElement(); showAutomationLaneBtn.mouseClickElement({ isShift: true, isOption: true, }); } } function main() { // Axctivate Pro Tools sf.ui.proTools.appActivate() //Invalidate Pro Tools main window. sf.ui.proTools.mainWindow.invalidate(); //Get selected tracks const originalTracks = sf.ui.proTools.selectedTrackNames; //Show automation Lanes showAutomationLanes(); //Do for each track. sf.ui.proTools.selectedTracks.trackHeaders.slice().map(track => { //Select track track.trackSelect(); //Scroll track into View track.trackScrollToView(); //Fetch track title let selectedTrackTitle = track.title.invalidate().value; //Fist automation lane on selected track let automationLane = sf.ui.proTools.mainWindow.children.whoseTitle.endsWith("Automation Lane").filter(f => f.title.invalidate().value.indexOf(selectedTrackTitle) === 0)[0]; // const currentVisibleLane = automationLane.popupButtons.whoseTitle.is('Lane view selector').first.value.invalidate().value; //String to identify sends and setting const insertIndentifier = '(fx a)'; const settingName = 'Reduction' if (automationLane.popupButtons.whoseTitle.is('Lane view selector').first.value.invalidate().value !== settingName) { let a = automationLane.popupButtons.whoseTitle.is('Lane view selector').first.popupMenuSelect({ menuSelector: items => items.filter(item => item.path[0].indexOf(insertIndentifier) >= 0 && item.path.indexOf(settingName) >= 0)[0], onError: 'Continue', }); } }); //Restore previously selected tracks sf.ui.proTools.trackSelectByName({ names: originalTracks }); sf.ui.proTools.selectedTrack.trackScrollToView(); sf.ui.proTools.trackSelectByName({ names: originalTracks }); } main();
samuel henriques @samuel_henriques
UPDATED: made improvements to ease change of insert or setting
- TTomás Frias @Tomas_Frias
Hi Samuel,
thanks a lot for your help, it works!
Anyway is there any option to show the automation line in the track and not the "lane" if you know what I mean.Thanks again for your help
Tomás Frias.
samuel henriques @samuel_henriques
hahaha, sorry I read line as lane,
Here you go:
function main() { // Axctivate Pro Tools sf.ui.proTools.appActivate() //Invalidate Pro Tools main window. sf.ui.proTools.mainWindow.invalidate(); //Get selected tracks const originalTracks = sf.ui.proTools.selectedTrackNames; //Do for each track. sf.ui.proTools.selectedTracks.trackHeaders.slice().map(track => { //Select track track.trackSelect(); //Scroll track into View track.trackScrollToView(); //Fetch track title let selectedTrackTitle = track.title.invalidate().value; // Automation view popup const automationView = sf.ui.proTools.selectedTrack.popupButtons.allItems[2] //String to identify sends and setting const insertIndentifier = '(fx a)'; const settingName = 'Reduction' if (automationView.invalidate().value.value !== settingName) { let a = automationView.popupMenuSelect({ menuSelector: items => items.filter(item => item.path[0].indexOf(insertIndentifier) >= 0 && item.path.indexOf(settingName) >= 0)[0], onError: 'Continue', }); } }); // //Restore previously selected tracks sf.ui.proTools.trackSelectByName({ names: originalTracks }); sf.ui.proTools.selectedTrack.trackScrollToView(); sf.ui.proTools.trackSelectByName({ names: originalTracks }); } main();
the last step selects the original selected tracks, if you don't need those, just delete them. It'll make the script faster.
this bit:// //Restore previously selected tracks sf.ui.proTools.trackSelectByName({ names: originalTracks }); sf.ui.proTools.selectedTrack.trackScrollToView(); sf.ui.proTools.trackSelectByName({ names: originalTracks });
hope this is it
- TTomás Frias @Tomas_Frias
WOW!
Samuel it works like magic hahaha.
Thanks a lot Master!!samuel henriques @samuel_henriques
Great,
Just to clarify, I'm just a young padawan, the Master is Kitch.
And Christian is Yoda! Hahah!- TTomás Frias @Tomas_Frias
I can only say, may the force be with you!