This month we take another look at Cubase's Macro facility and discuss a selection of examples for adding some rather neat features to the program.
With so many new Cubase books appearing on the market these days, I often wonder how long it will be until we see such titles as Cooking With Cubase, although I admit that I'm not completely blameless in this department. Unfortunately, from a personal perspective, I'm no Nigel Slater; but to honour one of the UK's finest TV chefs, in this month's Cubase Notes I offer you instead — wait for it — the Cubase Macro Cookbook.
For the uninitiated, Cubase's Macros allow you to program a sequence of Key Commands as a single Key Command, and the Macro functionality is accessed from the Key Commands window (File / Key Commands) by clicking the Show Macros button. You can add a new Macro by clicking the New Macro button, typing a name and pressing Return. To add commands to the Macro, simply select the required Key Command in the upper part of the window and click the Add Command button. Macros can be assigned to a Key Command from the Macros Category, or triggered from the Edit / Macros submenu. For a more detailed introduction and overview of Macros, see January 2003's Cubase Notes (www.soundonsound.com/sos/jan03/articles/cubasenotes0103.asp).
Hide & Show Soufflé
To start with, here's a simple recipe I call 'Toggle Concise Project Window'. If you look at the Editors Category in the Key Commands window, you'll notice that the Show/Hide Infoview, Inspector and Overview commands for the Project window are all available as Key Commands. So, assuming you usually enable all three of these at once (and you'll need to have all three visible or not visible for this to work properly), you can toggle all three of these commands in one Macro and flip between the two Project window views with one Key Command — Alt/Option+Shift+C, for example. Simple, but useful; and if you only use the Infoview and Inspector, for example, you could leave the Hide/Show Overview command out of the Macro.
Unfortunately, there aren't any other windows where global hide and show commands are possible: although Cubase SX's advanced Score Editor features the Icon and Filter bars, which can both be toggled from the window's toolbar, for example, these particular toggle commands aren't available as Key Commands. However, you can assign the individual filters on the Filter bar to Key Commands to turn them on and off, so these could be grouped together into a Macro if required. Staying with SX's Score Editor, a seemingly good idea would be to toggle the display of a selection of Symbol Palettes with a Macro, since these can be assigned to Key Commands. Unfortunately, though, the Key Commands for the Symbol Palettes only open the palettes — selecting the same Key Commands again won't close the palettes.
Quick Fried Grooves
Now for a Macro that can save you time: 'Slice Audio Loop'. We looked at the commands required to slice an audio loop in Recycle fashion in September 2002's Cubase Notes (www.soundonsound.com/sos/sep02/articles/cubasenotes0902.asp), but why not automate this process with a Macro? Add the following commands to a new Macro in this order: Edit-Open/Close Editor, Hitpoints-Calculate, Hitpoints-Create Audio Slices, and assign it to, say, Alt/Option+Shift+L. Now, when you have an imported Audio Event you want to play in time with the current Project's tempo, select it and use the Slice Audio Loop Macro — and nine times out of 10, the default settings will work their magic.
If you wanted to save even more mouse clicks, you could create another Macro with the same commands, but add Hitpoints-Create Groove Quantize before Hitpoints-Create Audio Slices — let's call it 'Slice & Groove' and assign it to Alt/Option+Shift+G. This way, a Groove Quantize preset is added to the Quantize menu at the same time you create the audio slices. I experimented with adding extra commands after the basic Slice Audio Loop Macro as well, but, unfortunately, it seems that currently no command in a Macro can be executed after Hitpoints-Create Audio Slices, even basic Transport commands.
Project Cursor Sauté
When you're working with video in Cubase, it's incredibly useful to be able to nudge the Project Cursor forward and backwards in single-frame steps. When the Project's Display Format is set to a frame rate, this is easy because the Nudge Up and Down buttons on the Transport Panel (the '+' and '-' icons) always nudge the Project cursor by the smallest unit in the current Display Format, which would, of course, be single frames when you're working with a frame rate. However, since we tend to write music in terms of bars and beats rather than seconds and frames, what happens when the Display Format is set to Bars+Beats instead? Since the smallest unit in Bars+Beats mode is ticks, the Nudge Up and Down buttons now nudge the Project cursor in single-tick steps, rather than frames.
Fortunately, the number of frames per second can be neatly divided into the number of ticks per second when you're working with 24- or 30-frame video, meaning that a single frame is worth 40 and 32 ticks respectively. So to nudge the Project Cursor by a single frame with video in either of these frame rates when the Display Format is set to Bars+Beats, all you have to do is press either the Nudge Up or Down button over and over again, the required number of times — great! As you can imagine, Macros can easily take the strain out of such repetition, and all you need to do is program a Macro to trigger Nudge Up or Down the required number of times. Assign these Macros to Key Commands and it's now very easy to nudge by single-frame steps when working with bars and beats. I usually give these Macros names such as 'Nudge Up 1/24/40', 'Nudge Down 1/30/32', and so on.
There are other situations where it can be useful to create a Macro with a sequence of Nudge Up or Down commands — for example, it's easy to nudge in single frames when you're working with frames with the Nudge Up and Down commands, as we've seen, but what if you wanted to Nudge Up and Down a second? As you can guess, for 24-frame video, the answer is simply to create a 'Nudge Up 24' and a 'Nudge Down 24' Macro, each containing 24 Nudge Up or Down commands respectively. While these last two Macros might seem a little simplistic, I'm recommending them because they'll come in useful for another recipe in just a moment.
You'll often want to create a number of copies of an Event or Part when working with loops, and while Cubase offers a variety of tools to make copying objects fairly easy, wouldn't it be great to have a 'make three copies instantly' button, making a one-bar loop play over four bars, or a 'seven copies' button to cover eight bars? As we've already seen, Macros are a great way to trigger the same command over and over again; so, in theory, a 'copy three times' command should be easily created by simply creating a Macro that triggers the Duplicate command three times. If only it was that easy...
It turns out that triggering the Duplicate command three times from a Macro does exactly the same as using the Duplicate command once. I suspect the problem lies with the Macro sending the next command before the previous one has completed, which is something that could be addressed by Steinberg. My next thought was to build my own Duplicate command, by copying the current selection, moving the Project Cursor to the end of the selection (by using the Locator commands), and pasting — Edit-Copy, Transport-Locators to Selection, Transport-To Right Locator, Edit-Select None, Edit-Paste. However, this fails because the Paste command is somehow executed before the Project Cursor is moved, so the object being copied ends up being pasted to wherever the Project Cursor happens to be when you execute the Macro. Very frustrating, for sure, but at least it's a lesson learnt.
My final solution uses the Edit / Fill Loop command and is less flexible than I'd initially hoped, but hopefully it will serve to offer some other ideas for your own Macro experiments. First of all, create a new Macro called something like 'Copy 1x3' because what this Macro will do is a copy a selected one-bar object three times so it plays over four bars, although these numbers can easily be adapted. The way it works is quite simple: first set the locators around the selected object, move the Project cursor to the Right Locator (the end of the selection) and set the Left Locator to this position as well. Next, we'll move the Project Cursor forward three bars, set the Right Locator to the new position of the Project Cursor and trigger the Edit menu's Fill Loop command.
The secret to making this Macro work is how you move the Project Cursor forward by three bars, and guess what? We need to do this in single-tick steps with the aid of the Nudge Up command we created earlier, although this isn't as bad as it sounds. Because it's possible for a Macro to trigger another Macro, we can create a 'Nudge Up Beat' Macro with 20 'Nudge Up 24' commands, since there are 120 ticks in a 16th note (24 x 5 = 120) and four 16th beats in a quarter note.
So the finished Macro consists of: Transport-Locators to Selection, Transport-To Right Locator, Transport-Set Left Locator, Macro-Nudge Up Bar, Macro-Nudge Up Bar, Macro-Nudge Up Bar, Transport-Set Right Locator, Edit-Fill Loop. Activate it when you have a one-bar object selected, and you'll get three more copies after it. While this may not be the most exciting Macro you'll ever see, it hopefully illustrates a few points about what is and what's not possible, and will give you a few ideas for other Macros along the same lines. We'll present other recipes from the Macro Cookbook in future Cubase Notes, and, as always, if you come up with any interesting Macros, do email them to us at email@example.com.
If you're having difficulty persuading Cubase to let you create Macros, it's worth remembering that Cubase won't let you create another Macro if the last Macro in the list (probably the one most recently created) doesn't contain any commands. This can be a problem because it's quite common for people to want to create Macros as 'placeholders' and program them later on.