Logic Pro - Macro Megathread (2022)

Q: Why have I posted a new version of this thread?

A: Discourse locks threads when they get to a certain age, which means I'm unable to update the macros for use with recent versions of macOS/Logic when requested... or add new ones!

Please do let me know if you need help with any of these.


lpm


After installing any of these, pay attention to any green actions.

NB: These all work for me, but you may need to tweak them, depending on your screen configuration, macOS or software versions. Basic familiarity with KM will be very helpful.

I've now upgraded to Monterey, and I constantly tweak my Logic macros, so the versions uploaded here may not be up-to-date. If you like the idea of a macro but, for example, the AppleScript isn't working because you're on v10.7 onward, comment below and I'll do my best to update it for you.


Plugin Drill.kmmacros (178.0 KB)

Found Images - Notes

If the first available slot is not clicked successfully, you will need to replace the found images. These need to be quite precise, so I recommend using an image editing app to zoom in and crop each image.

- Mono:

Select a mono track and grab an image of the button highlighted below in red, including its edges.

- Empty Slot:

Grab an image of the text, "Audio FX" in an empty plugin slot, highlighted below in blue, without including the button edges.

CleanShot 2022-07-03 at 15.49.17

"Below Active/Inactive Plugin" Images:

These two really do need to be quite accurate..

  1. Insert any plugin in the first slot and grab an image of its button, making sure to include some of the empty slot below it. Deactivate the plugin and take a second image of the same area.

  2. For each of these, zoom in and crop them to two pixels around the lower blank button area:

Active Plugin Screenshot

Inactive Plugin Screenshot

- Buss Input Stereo Button:

Grab an image of the stereo icon of the buss or output that the currently selected track feeds, highlighted below in red, without selecting the button edges.

CleanShot 2022-07-03 at 15.54.37

Plugin Drill - Triggers

For each action in the Switch/Case group, you must add a path that navigates the plugin folder tree, ending at your desired plugin. A path is made up of the letters you need to type at each level of the menu, separated by a comma and space. (See below for examples.)

You can type each word fully if you like, but it isn't necessary, as long as the keystrokes navigate the menu successfully. However, there is one exception: For Waves plugins, always type the word "Waves" in full. This ensures that mono/stereo plugin instances are automatically accounted for.

As an example, say we want to load ValhallaRoom. One path would be: "Au, Val, ValhallaR".

Screenshot

CleanShot 2022-07-03 at 16.00.33

Another might be: "REV, ValhallaR".

Screenshot

CleanShot 2022-07-03 at 16.03.48


Strip Search.kmmacros (629.3 KB) ← Collection of 8 Macros!

Notes...
  • Strip Search - Instrument:

Prompts with a list of your Instrument Channel Settings. When one is selected, it will be loaded on the current track.

  • Strip Search - Mix Buss:

Prompts with a list of your Output Channel Settings. When one is selected, it will be loaded on the Output track. NB: This version only works when the Mixer has its own window. If you'd like me to adjust it to work with the mixer pane in the Tracks window, let me know.

  • Strip Search - Send:

Prompts with a list of your Bus Settings. When one is selected, a new Send will be created on the currently selected Audio or Midi track and the Bus Setting will be loaded for that Send.

  • Strip Search - Stack:

Prompts with an auto-generated list of your Library Patches. Select one and hit Enter. The patch will briefly be revealed in a Finder window, then loaded in Logic via drag-and-drop.

Demo Video

CleanShot 2022-06-20 at 14.55.01

  • Strip Search - Track:

Prompts with a list of your Audio Channel Settings. When one is selected, it will be loaded on the current track.

  • Inspector - CLOSE (SUB!):

A submacro which makes sure the Track Header isn't obscured.

  • Strip - New Instrument Track? (SUB!):

A submacro which creates an empty Instrument Track if one is not already selected.

  • Strip - New Send (SUB!):

A submacro which creates a new Send on the first available Bus.


Bypass:Mute:Solo:Clear Solo.kmmacros (75.8 KB)

Notes...
  • Tap = mute track(s) OR bypass plugin when plugin window is selected

  • Slightly longer press = solo selected track(s)

  • Double-tap = clear/recall solo


Apply My Defaults.kmmacros (53.8 KB)

Notes...

Handy when opening someone else's session on your machine. It will impose your defaults (screensets and so on), as found in your usual template and then save.


Set Buffer.kmmacros (27.9 KB)

Notes...

Change the number in the green action for different buffer settings.


A/B Two Plugins.kmmacros (50.0 KB)

Notes

Place your mouse over the bypass button of the first of two consecutive plugins (one of which is bypassed) and double-tap to save this position. From then on, no matter where the mouse pointer is, a single tap will quickly flip the bypass state for both plugins so you can hear them individually. Comes set to ⌥⌘A. If you'd like to set your own hotkey, be sure to set a press and release trigger.


Dynamic Buttons.kmmacros (54.3 KB)

Notes

Saves a position to click whenever you like. I use these often for incrementing/decrementing plugin presets. Position your mouse over whatever you'd like to click and long-press one of the hotkeys to save its position. From then on, no matter where your mouse pointer is, a single tap will click it. The two buttons come set to ⌃⌥1 and ⌃⌥2. If you'd like to set your own hotkeys, be sure to set a press and release trigger for each.


Click for Count In Only (Toggle).kmmacros (121.7 KB)

Notes...

Toggles the metronome between always active while recording and active only during the count-in.


Fade In:Out Prompt.kmmacros (102.8 KB)

Fade In:Out:EqP Prompt.kmmacros (103.5 KB)

Notes...

Prompts for fade length and then applies the fades/crossfades to the selected regions.


Fader Reset - Relative.kmmacros (56.3 KB)

Notes...

Select multiple faders in the Mixer window, then trigger this macro. It will set the fader with the highest value to 0db while maintaining the other faders' relative values.


Copy MIDI Up/Down.kmmacros (195.5 KB)

Notes...

These macros copy the selected midi notes up a fifth, down a fourth, down an octave or up an octave.


Chords to Divisi.kmmacros (62.1 KB)

Notes...

Separates a polyphonic MIDI region into multiple monophonic lines (user prompt for number of lines). Very useful when trying to turn chords into individual string parts, for example.


Region End to Playhead.kmmacros (41.2 KB)

Notes...

Handy if you want a region to end exactly at a certain point, for example: reverse cymbals that end on a downbeat. Place your playhead where you want the selected region to end, then trigger the macro.


Reset Tempo Data.kmmacros (49.0 KB)

Notes...

Removes an audio file's embedded tempo data and writes that of the current session to it instead. A time-saver whenever an audio file won't play ball with flex-time.


Select Muted Regions (on selected track).kmmacros (26.0 KB)

Notes...

Does what it says on the tin! This is the simplest macro on the list, but it's handy.


Set freeze to pre-fader.kmmacros (78.4 KB)

Notes...

Sets the selected track's freeze function to the green Pre-Fader version, which is generally what you want if you're trying to reduce CPU usage induced by plugin chains. I could make this a toggle, but I never really use the Source Only option.


Trim region edges to nearest bars.kmmacros (41.1 KB)

Notes...

Trims the selected region's start and end points to the nearest bars. Saves a few clicks, once in a while. Uses custom Logic key commands, so be sure to set them to whatever yours are before trying it. The actions are labelled for this purpose.


Delete All Groove Templates.kmmacros (80.4 KB)

Notes...

Does what it says on the tin.


Delete Unused Audio Files.kmmacros (50.0 KB)

Notes...

Does what it says on the tin.


Varispeed Region to Project Tempo.kmmacros (119.6 KB)

Notes...

Automates the process of applying varispeed to a region so that it syncs with the project tempo. Great for sloshy drum loops!


Bounce Tracks.kmmacros (239.1 KB)

Notes...
  • Enter the number of tracks to bounce (defaults to ALL).
  • Choose a name for the bounce Folder.
  • Choose where the bounce folder will be created.

Tracks are bounced to a chosen folder or the project location (default), named according to the project name. If subsequent batches of tracks are bounced from the same session, the folder numbers are incremented. When the number of tracks are defined (i.e. not ALL), a progress bar will be shown.

The green actions contain key commands; change them to match your own before use.


Bounce All Markers.kmmacros (74.6 KB)

Notes...

Bounces individual audio files for each marker section with a prompt for the number of markers to bounce, format (WAV/AAC) and the option to bounce from the first marker regardless of current playhead position. The resultant files will be named according to the marker names and bounced to a folder on the Desktop named according to the project title. Green actions are Logic Key Commands; you may need to adjust the simulated hotkeys to match your own setup.


Vocalign Auto.kmmacros (97.8 KB)

Notes...

Prompts for number of tracks to sync to the the Master Track, and automates the entire process. It executes Plugin Drill (at the top of this post) as a submacro.

Copy Selection to Focused Track.kmmacros (28.0 KB)

Notes...

If you have Select tracks on region/marquee selection turned OFF:

  • Select the destination track
  • Select the regions you want to copy
  • Trigger this macro.

If you have Select tracks on region/marquee selection turned ON:

  • Enable the disabled action
  • Select the regions you want to copy
  • Trigger this macro and follow the instructions.


sd

Do you ALSO have a Stream Deck? If so...

First off, get the KM Link Stream Deck plugin if you don't already have it. You will use this plugin to select the macros below. The important differences between this and the bundled KM plugin are:

  • It passes on a parameter (TriggerValue) to KM.

  • It allows you to move the buttons without macros becoming unlinked.

  • You can select the macros from within the plugin's drop-down menu, with the most recently edited macro showing at the top of the list.

Example Profile.streamDeckProfile.zip (150.6 KB)

Now import this profile using the Stream Deck app. It contains folders and buttons pertaining to the following macros, which you can then copy to your own Logic profile... if you like them.

Ready? Ok then...


Colours.kmmacros (71.8 KB)

Notes...

This is a region colour palette for your Stream Deck. The colours are selected by their location in relation to the centre of a found image of the colour picker's title, so if you don't want to use the same colours as I do, you will need to adjust these coordinates accordingly. I tried to figure out a quicker way to obtain these coordinates, but ended up using the mac screenshot tool to get them. If anyone knows a better way, do let me know.


Fade - EqP.kmmacros (101.0 KB)

Fade - In:Out.kmmacros (100.8 KB)

Notes...

These macros apply fades to selected regions, based on preset values set to Stream Deck buttons. There are two rows; one for in/out fades and another for crossfades. Both rows also contain a button with a question mark, which will prompt you to enter your own fade length.


New Audio Track.kmmacros (79.2 KB)

Notes...

Creates a new audio track whose input matches the text entered into the KM Link parameter box.


Region Gain Presets.kmmacros (55.7 KB)

Notes...

Increments region gain up or down by increments of 1db, 3db, and 6db.


af


I'd like to direct you to another post I've made about triggering Stream Deck profiles for Logic plugins. It's too involved to add here.


I hope you found something useful here. I've put in the hours and got these all working reliably on my system. Some of them use found images, so they may need some modification, depending on your screen resolution. It should be self-evident which images need to be captured, but let me know if you need clarification. If any of these don't work for you, it may be due to the configuration of your screens differing from mine. In that case, you may also need to go through the offending macro and check that it's searching for images in the correct screen.

At the very least, I hope they can act as starting points to be adapted to fit your needs. I've tried to make them as easy to understand and customise as possible, so I can't see why they wouldn't work for you too!

15 Likes

Thank you noisneil! Very generous.

1 Like

Often refer back to these. Many thanks!

1 Like

This seems like a good place to contribute my macros. They are HUGE time savers! Since logic doesn't have the track and file batch renaming capabilities like, for example, protools has, I decided to turn to KM for help. I've created basic macros for track renaming, file renaming, and track copying and I'll briefly explain the needs that gave rise to the macros:

Track Renaming..
I do LOTS of live show multitrack recording. Over 20+ years it became obvious that having 50 or 500 copies of Kick#01.wav could be very problematic. The best way I found to generate unique file names was to pre-name tracks with something unique before recording. This macro changes an existing four letter designator with a new one. I use L for logic, and 3 letters to indicate year, month, and project/scene. So, for example, a designator on all 40 tracks of _LVBC can quickly be changed to _LVBD or whatever. That will make your recordings unique by take/shoot/project such as Kick_LVBC#01.wav, Kick_LVBD#01.wav and so on. This macro also names your tracks with a number in order: 01_Kick, 02_Snare, and so on. This macro assumes: 1-You have logic opened to the main window with first track selected. 2- Your tracks are already in the format 00_Track Name_ABCD (macro could be updated to add prefix and suffix if it doesn't already exist). 3- Logic key command Option-T is set to rename track & down arrow is set to select next track. You'll need to examine the macro to see if there are any other specific assumptions.

Logic_Rename Tracks Macros.kmmacros (11.6 KB)

Audio File Renaming
Now let's say you recorded hundreds of multitrack audio files and you want to rename them after recording WITHOUT breaking the link between Logic and the audio files. That's what this macro is for. Have your project audio window open and run Rename Audio Files. PRO TIP - Do you have several Logic projects which reference the same audio files?? Rename the audio and update the links in all of them at the same time by opening all the logic files before you run this script in one of them. The links in all open logic projects get updated. YOU MUST SAVE EACH LOGIC PROJECT AFTER RENAMING THE AUDIO FILES. Renaming an audio file incurs a time delay, so there is a delay in the loop processing to accommodate this. You may need to adjust the delay timing to not skip renaming some files. Assumptions are made for this macro as well for rename audio file and select next audio file Logic key commands.

Logic_Rename Audio Files Macros.kmmacros (9.7 KB)

Prepend to Audio File Name
As above, but add a prepend value to the audio files.

Logic_Prepend Audio File Name Macros.kmmacros (7.7 KB)

Copy Track with Same Track Object
In the above scenario where I multitrack record a live performance I will often record several takes of a single song. Each take is recorded to a click track, so timing is the same. This allows combining all the takes into take folders for take comp editing in logic. This macro eliminates the tedium of creating track copies for lining up the takes to pack into take folders. This could be expanded to do the work of selecting and moving all the audio regions for each take into the correct positions and creating the take folders and cleaning up the extra tracks afterword, but my unfamiliarity with KM is a great impediment to my progress accomplishing these additions.

Create Take Tracks.kmmacros (5.7 KB)

--
I could see these being a starting point for a complete mini-app for bulk file and track operations in Logic. I have the programming chops, but severely lack the familiarity with KM to do this. I'm constantly banging my head against the wall trying to figure out how to make KM do what I imagine in my head.

Feel free to add these to your library of Logic macros for everyone's benifit.

3 Likes

Awesome!!!

Just curious: with the Take Tracks macro, what's the purpose of creating new tracks when recording directly over the existing tracks automatically creates take folders? I've probably misunderstood haven't I. :joy:

Is it because you want to manually align the takes before packing them?

Yes, it's a scenario where regular take recording isn't possible and manual alignment of recordings made separately is necessary. Think of a band live on stage doing a show performing songs where each song is to a playback click track. Each show is filmed with multiple camera angles and recorded multitrack. In subsequent shows (takes) it is impossible to record "over" each instrument and have all takes for all songs line up with with the previous show's recordings (normal automatic take folder creation). However, using the first click (also recorded from the playback to the multitrack recording) from each song, all the tracks can be manually aligned and then packed into a take folder for easy multitrack swipe comping. I can use a Logic group (turn editing on in group settings) to swipe comp all 40 tracks in one go to match the live camera edit. The result is a multitrack audio edit which perfectly matches the live camera edit. When doing this manual alignment for 30-40 tracks it gets really tedious. I plan to automate more of the process - as much as I can - using KM.

As a side note I'll comment on creating track copies of a) same track object vs b) new object with same settings. a) is way less resource intensive than b) when you are talking about 40 tracks x 9 or more takes = 360+ tracks. Of course, once you align and pack the take folders, you delete the extra tracks and take it back down to 40.

Yeah makes sense! Personally, I'd probably either:

  • stick all the tracks in a summing stack and duplicate the stack.
  • record each take as an alternative, go through and align them, then pack all the alternatives as takes.

...but that's just me. I lean more towards using alternatives as that's what the feature was designed for.

Hey Neil Thanks for the update!
I'm testing it on my system. Some of them works flawlessly some are not. Digging KM to debug, never been a programmer but fun to dig in. Any updates or new macros after posting it?
Many thanks and cannot wait how your macros will support my workflow.
Thanks again. You're the man!

1 Like

Hi! As it says at the top of the thread, if there's a macro that isn't working, let me know which and I'll try and help. :+1:t3:

1 Like

Now I'm debugging
Strip - New Instrument Track? (SUB!)

but cannot find the image which is path

/Users/noisyneil/Documents/- MY DOCUMENTS/Keyboard Maestro Stuff/Found Images/- Logic/Strip - New Instrument Track? (SUB!)/Pause until track created 9614366.png

what is it?

Oops. I left it set to getting the image from a path, which is a habit I've adopted to try to keep the KM Editor light and snappy. This is the image it's looking for:

image

1 Like

Thanks!

This macro also has your image file path!
I'll keep update which has same conditions.

Oops again. I've updated it to include the images.

Hi there!

Really enjoying this thread :slight_smile:

I'm very new (as of today) with KM and I'm trying to create my very first macro but have no idea how.
I would like a macro that will bounce regions in place.

After selecting a region KM should perform the following:

  • pop up asking how many tracks/regions should be bounced in place
  • "Set Locators/Loop by Regions/Events/Marquee and Enable Cycle/Loop” by pressing 'U'
  • hit keystroke 'ctrl+B'
    in popup window:
  • Destination: 'new track'
  • Source: 'Mute'
  • 'include instrument Multi-Outputs
  • 'include Audio Tail File
  • 'include Audio Tail in Region
  • Press 'OK'

I know what I want to achieve but have no idea how to set this up...

Hi and welcome to the forum! I'm glad to hear you're getting some use out of these macros. :blush:

Here's a macro that does what you asked for:

Bounce In Place.kmmacros (25 KB)

Macro screenshot

1 Like

I'm trying to script my own custom macros based on your scripts.

How do you deal with the submenu kinda windows & menus?
For example, MIDI transform window


In this case, I want to confirm if the mode menu is set to Apply operations to selected events

or

submenu inside the arrange window

image
in this case, I want to trigger Functions menu.

Since my work environment changes often (using ext monitor / just using laptop itself) I'm trying to avoid use mouse position commands but there are so many variables when just using found image commands.

In case of Bounce Tracks that you've shared

I can see you used Apple script when dealing checkboxes.
Is Applescript only way to deal with these kind of isssues?

Hope you have tips and easier way to get the answer.
Thanks again

I'd do this:

activate application "Logic Pro X"
tell application "System Events"
	tell process "Logic Pro"
		
		if value of pop up button 1 of window 1 is "Apply operations to selected events" then
		else
			click pop up button 1 of window 1
			keystroke "a"
			key code 36
		end if

	end tell
end tell

Here's a script for that:

activate application "Logic Pro X"
tell application "System Events"
	tell process "Logic Pro"
		
		set tracks_window to title of first window whose title contains "- Tracks"
		
	click menu button "Functions"  of group 1 of group 1 of group 4 of window tracks_window
		
	end tell
end tell

It's certainly the best one I know of. KM doesn't have any radio button/check box actions, and using found images can get cumbersome. AS allows you to easily test the condition of the button/box and click if necessary, in one line.

1 Like

Wow Thanks again @noisneil
I should take a shot digging AS.
Never learned scripting in a classic way.

1 Like

Awesome! Thank you so much!

1 Like

And by the way this request would be annoying but could you make a video capture making KM macros for Logic? (tutorial vids would be appreciated so much.)
It would be so helpful seeing someone skilled user scripting KM. I think I'm get lost so often during making one short macro.