For a while, I've been wandering around the possibility that O S C would take benefit of articulation sets in Logic to autoload them on a grid. Logic version : 10.7.7, O S C : v.1.22.0
And voilà, it works.
REQUIREMENTS & CONFIGURATION
-
install, use or copy-paste the attached custom module .
It is well commented so you can adapt to your likings (colours, articulation groups, plist directory, etc.).
More specifically :
line 222 : adapt to the OSC message that gets the track name (in my case, I use Touch OSC as wrapper between Logic and O S C. I'm using the Logic Pad template, set on page 3 - please check your Control Surface in Logic).
lines 47-146 : you can change the color and the association between the icon in Articulation Set and the matching color.
line 35 : use your directory that contains the articulation sets plist files.
Please note that it requires a couple of extra libraries. -
On your O S C template , you will need those controls
2 variables called curArtList and curArtColors
1 switch:
set to layout = grid. I recommend also putting 4 in gridTemplate (=columns) and wrap =soft. Give it a large size if you use many articulations.
set the values to @{curArtList} and if you want to benefit from colored buttons, copy-paste this in css and adjust to taste.
Code:
JS{{
var colRAW = @{curArtColors}
console.log(colRAW);
var colors=colRAW.split(",");
var css = 'value {border-radius:5px;font-family:"Avenir Next Condensed";font-size:12px;border:1px solid #000000;}\n'
for (var i = 0; i <= colors.length; i++) {
css += "value:nth-child(" + (i) + "){--color-fill:" + colors[i-1] + "ee;min-height:28px;}\n"
css += "value.on:nth-child(" + (i) + "){--color-fill:" + colors[i-1] + "ff;min-height:28px;border:1px solid #ffffff;text-transform:uppercase;font-size:14px;}\n"
}
console.log(css);
return css
}}
You can adjust the address and preArgs to your configuration. I use address = /control and preArgs = [1,32] since my articulations are inspired by Spitfire's UACC where articulation switching is driven by CC32.
USAGE
- In Logic, create an articulation set and set the articulations, input and output as you wish. If you want to do like me, then all the input are controlled by CC32. Output depends on your plugin. For example, for VSL, you'd want keyswitches by Note On, for Spitfire, either Note on & CC32 (if UACC KS), etc. You can use articulation symbols to benefit from colour coded buttons.
- Save this art set as a file. You can give it any filename you want, but you'll need to put a short name in brackets .
For example : VSL Synchron Strings Pro [SSP] .plist - In Logic, create a track with the following requirements:
The track name should contain the short name (no brackets needed). For example : VSL SSP Violins 1.
You must set the related articulation set on the track.
Run O S C, set the track in Logic, and voilà, you should see the switch control auto-filled with the articulations put in the articulation sets and coloured the way you defined it using the articulation symbols.
HOW IT WORKS
When O S C is running (or each time you save the custom script), O S C scans your articulation directory and reads all plist files and fills 2 variables with articulations and colours.
When you select a track, the track name is sent from Logic to O S C (this is done by your configuration, not my script). The custom modules receives this data and looks through all articulations to see if the track name makes reference to a known articulations set. If it finds one, then it's setting the articulation list and the colours in 2 widgets variable.
Then the switch widget is automatically refreshed with the content of the 2 variable widgets to update its values and its style (css).
DISCLAIMERS
This hint is provided as this, it is not a finished product nor a commercial product. I may help if you're struggling but no more than this. It's experimental, far from optimized but it works wonderfully for me.
Beware of the track name, some "middleware" (TouchOSC or OSCulator) have a tendency to cut the track label, sometimes altering the short name that triggers everything.
I have a big template with a lot of articulations sets, sometimes the switch widget takes a moment to refresh once I select a track (less than 1s though).
I am not endorsed by any stakeholders cited above (Apple, Logic, Open Stage Control, VSL, Spitfire, etc.).
I can't guarantee that this script will work in future versions of Logic or O S C.
I hope you can enjoy this script though.
I will post the same content later in Open Stage Control forum.
PS: here's a capture of my O S C template, with SSP Violins 1 selected.
myCustomModule.js.zip (4.5 KB)