Marker Macros, clip/track color codes, and more help needed.

Discussion about: tracktion.com
Post Reply New Topic
RELATED
PRODUCTS

Post

I thought I would post some macros I've been using lately and also ask for some help with a new one. These are mostly in the macros thread, but I revisited some now that 'absoluteMarker' works and I figured out how to add colors to clips/tracks via macro. I'm going to post the color codes in a new post below for reference.

This is one of my favorites. You can add named markers on the fly (now with color). I have one for each part of a song (alt+c = red chorus marker, alt+v = yellow verse marker, etc). I can have a song fully marked out after a few passes while the band listens to takes.

Code: Select all

//Named Marker on the fly with color option
var clip = Tracktion.insertClip ('absoluteMarker');
//other option is 'barsBeatsMarker' 
Tracktion.deselectAll();
Tracktion.addObjectsToSelection (clip);
Tracktion.setName (clip, "CHORUS");
var clip = Tracktion.getSelectedEditElements ('clip');
//change code ff****** to change color
clip[0].setProperty ('colour','ff884cff');
This is the basically same as above, but it leaves the marker selected so you just push Tab and you can name it yourself while the song still plays. Updated with color option.

Code: Select all

//Marker on the Fly (press Tab to name)
var clip = Tracktion.insertClip ('absoluteMarker');
Tracktion.deselectAll();
Tracktion.addObjectsToSelection (clip);
var clip = Tracktion.getSelectedEditElements ('clip');
//change code ff****** to change color
clip[0].setProperty ('colour','ff884cff');

Now the one problem with placing markers for a song in a few passes is that the numbers get all jumbled. So this is one I'm working on that numerically re-orders all the markers. You just have to select the first marker before you run it. It's OK to laugh at how silly it is. The problem is that while it goes up to 29 markers, the last one will always be 29. If anyone knows how to get the macro to stop at the last one, or has a better way to do it please let me know. Obviously there is, but I have no training with code so this is just me piecing things together best I can. It's still quite useful as you can just push Tab twice to re-number the last one manually.

Code: Select all

var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','1');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','2');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','3');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','4');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','5');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','6');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','7');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','8');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','9');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','10');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','11');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','12');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','13');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','14');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','15');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','16');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','17');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','18');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','19');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','20');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','21');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','22');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','23');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','24');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','25');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','26');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','27');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','28');
Tracktion.selectItem ('right');
var clip = Tracktion.getSelectedEditElements ('clip');
clip[0].setProperty ('markerID','29');
So if anyone has any input on that it would be appreciated. I'd be interested in seeing any new macros as well, or any macro discussion. I'm finding it fun just learning and experimenting. I'm still interested in being able to select specific tracks, or markers by name (or number).

Post

Here's the color codes. I have trouble figuring out what to call everything so you'll have to do that yourself. It starts from the left (RED) and goes right.

ffffaa00
ffff884c
ffffc44c
ffffff4c
ffc4ff4c
ff88ff4c
ff4cff4c
ff4cff88
ff4cffc4
ff4cffff
ff4cc3ff
ff4c88ff
ff4c4cff
ff884cff
ffc34cff
ffff4cff
ffff4cc3
ffff4c88

If the Dev's read this, can we get GREY (most importantly), and maybe WHITE and BLACK (or dark grey) and BROWN?

Post Reply

Return to “Tracktion”