# cubase ninja - pro tools-style trim automation macro

**URL:** <https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383>\
**Category:** Cubase\
**Tags:** cubase-older-version\
**Created:** [April 13, 2013, 12:54am UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383 "2013-04-13T00:54:30Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![lukasbrooklyn](https://avatars.discourse-cdn.com/v4/letter/l/e95f7d/32.png) [@lukasbrooklyn](https://forums.steinberg.net/u/lukasbrooklyn)\
**Post date:** [April 13, 2013, 12:54am UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/1 "2013-04-13T00:54:30Z")

</div>

ok, here’s another one, it’s a combo of a macro and a PLE script. it does pro tools style automation trim, without having to resort to ‘trim’ or ‘loop’ functions on the automation panel.

(what it does is, you select a range, it creates automation events on the edges of the selection, then jumps a frame to the left of the left edge and creates a point, and a frame to the right of the right edge, then selects the inner left and right points and switches back to the the select tool, so you are ready to go and scale / trim your selection, without affecting the rest of your automation curve. pretty cool, for my needs anyways.)

[https://dl.dropboxusercontent.com/s/gjjt6w2yebw717l/brooklyn\_automation\_trick\_custom\_macro.mp4](https://dl.dropboxusercontent.com/s/gjjt6w2yebw717l/brooklyn_automation_trick_custom_macro.mp4)

---

<div class="post-metadata">

**Author:** ![Winter\_Rat](https://dub1.discourse-cdn.com/steinberg/user_avatar/forums.steinberg.net/winter_rat/32/217_2.png) [@Winter\_Rat](https://forums.steinberg.net/u/Winter_Rat)\
**Post date:** [April 13, 2013, 3:10pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/2 "2013-04-13T15:10:36Z")

</div>

Hi, looks great.  
But one can use line tool with the same result and no need to make ranges.

Cheers

---

<div class="post-metadata">

**Author:** ![lukasbrooklyn](https://avatars.discourse-cdn.com/v4/letter/l/e95f7d/32.png) [@lukasbrooklyn](https://forums.steinberg.net/u/lukasbrooklyn)\
**Post date:** [April 13, 2013, 3:50pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/3 "2013-04-13T15:50:07Z")

</div>

> [@Winter Rat](#):
>
> Hi, looks great.  
> But one can use line tool with the same result and no need to make ranges.
> 
> Cheers

if you use the line over existing automation, you will overwrite whatever is already written there; this is more like ‘trim’ without using actual trim functionality on the automation pane (=you can scale the curve that resides in your selected area).

---

<div class="post-metadata">

**Author:** ![Winter\_Rat](https://dub1.discourse-cdn.com/steinberg/user_avatar/forums.steinberg.net/winter_rat/32/217_2.png) [@Winter\_Rat](https://forums.steinberg.net/u/Winter_Rat)\
**Post date:** [April 13, 2013, 4:47pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/4 "2013-04-13T16:47:19Z")

</div>

yes, you’re right. how do you insert automation events?

---

<div class="post-metadata">

**Author:** ![lukasbrooklyn](https://avatars.discourse-cdn.com/v4/letter/l/e95f7d/32.png) [@lukasbrooklyn](https://forums.steinberg.net/u/lukasbrooklyn)\
**Post date:** [April 13, 2013, 7:41pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/5 "2013-04-13T19:41:53Z")

</div>

> [@Winter Rat](#):
>
> yes, you’re right. how do you insert automation events?

that one’s funny: if you edit - copy - edit - paste an automation range, it creates automation events at the edges of range.

---

<div class="post-metadata">

**Author:** ![steve](https://dub1.discourse-cdn.com/steinberg/user_avatar/forums.steinberg.net/steve/32/193789_2.png) [@steve](https://forums.steinberg.net/u/steve)\
**Post date:** [April 13, 2013, 8:53pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/6 "2013-04-13T20:53:23Z")

</div>

Nice. Are you posting the steps, or just the idea?

---

<div class="post-metadata">

**Author:** ![lukasbrooklyn](https://avatars.discourse-cdn.com/v4/letter/l/e95f7d/32.png) [@lukasbrooklyn](https://forums.steinberg.net/u/lukasbrooklyn)\
**Post date:** [April 13, 2013, 9:52pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/7 "2013-04-13T21:52:53Z")

</div>

> [@SteveInChicago](#):
>
> Nice. Are you posting the steps, or just the idea?

sorry guys working towards a deadline on a cue, hopefully tomorrow i will type the commands out it’s quite long.

---

<div class="post-metadata">

**Author:** ![Winter\_Rat](https://dub1.discourse-cdn.com/steinberg/user_avatar/forums.steinberg.net/winter_rat/32/217_2.png) [@Winter\_Rat](https://forums.steinberg.net/u/Winter_Rat)\
**Post date:** [April 14, 2013, 7:36am UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/8 "2013-04-14T07:36:42Z")

</div>

> [@lukasbrooklyn](#):
>
> > [@Winter Rat](#):
> >
> > yes, you’re right. how do you insert automation events?
> 
> that one’s funny: if you edit - copy - edit - paste an automation range, it creates automation events at the edges of range.

😃 Cool. This is a brilliant discovery. The rest is easy. Thanks.

---

<div class="post-metadata">

**Author:** ![lukasbrooklyn](https://avatars.discourse-cdn.com/v4/letter/l/e95f7d/32.png) [@lukasbrooklyn](https://forums.steinberg.net/u/lukasbrooklyn)\
**Post date:** [April 15, 2013, 2:46pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/9 "2013-04-15T14:46:22Z")

</div>

> [@Winter Rat](#):
>
> > [@lukasbrooklyn](#):
> >
> > > [@Winter Rat](#):
> > >
> > > yes, you’re right. how do you insert automation events?
> > 
> > that one’s funny: if you edit - copy - edit - paste an automation range, it creates automation events at the edges of range.
> 
> 😃 Cool. This is a brilliant discovery. The rest is easy. Thanks.

it’s the rest that has proven quite a challenge. anyhow, here’s the macro as best as i could tweak it thus far. there is still an issue, and i’m hoping you can help me fine-tune that one: if there are more automation tracks for the given channel, the PLE script (=the last step in the macro) selects all the automation events inside the range for all the automation tracks on the given channel. in other words, i need to write a PLE script that selects the automation events inside the cycle, but only on the track for the one parameter you are trying to trim.

(edit: you could actually see this as an added functionality… in that all the parameter automation on the given track in the given range gets selected, so you are free to make adjustments to more parameters. still, i am wondering if someone can make a 'select automation events for the parameter on the selected track in the selected range. no matter what combination of PLE commands i tried i couldn’t come up with one.)

–the macro:  
edit - copy  
edit - paste  
transport - locate selection  
transport - nudge -1 frame  
edit - left selection side to cursor  
transport - locate selection end  
transport - nudge +1 frame  
transport - nudge +1 frame  
edit - right selection side to cursor  
edit - copy  
edit - paste  
transport - locate selection  
transport - locate next event  
edit - left selection side to cursor  
transport - locators to selection  
tool - select tool  
process project logical editor - “your PLE script to select automation inside cycle” (see below)

–the PLE script:  
media type equals automation  
position inside cycle PPQ  
//  
function - select

---

<div class="post-metadata">

**Author:** ![distante](https://dub1.discourse-cdn.com/steinberg/user_avatar/forums.steinberg.net/distante/32/591_2.png) [@distante](https://forums.steinberg.net/u/distante)\
**Post date:** [April 15, 2013, 7:10pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/10 "2013-04-15T19:10:41Z")

</div>

> [@lukasbrooklyn](#):
>
> it’s the rest that has proven quite a challenge. anyhow, here’s the macro as best as i could tweak it thus far. there is still an issue, and i’m hoping you can help me fine-tune that one: if there are more automation tracks for the given channel, the PLE script (=the last step in the macro) selects all the automation events inside the range for all the automation tracks on the given channel. in other words, i need to write a PLE script that selects the automation events inside the cycle, but only on the track for the one parameter you are trying to trim.
> 
> (edit: you could actually see this as an added functionality… in that all the parameter automation on the given track in the given range gets selected, so you are free to make adjustments to more parameters. still, i am wondering if someone can make a 'select automation events for the parameter on the selected track in the selected range. no matter what combination of PLE commands i tried i couldn’t come up with one.)
> 
> –the macro:  
> edit - copy  
> edit - paste  
> transport - locate selection  
> transport - nudge -1 frame  
> edit - left selection side to cursor  
> transport - locate selection end  
> transport - nudge +1 frame  
> transport - nudge +1 frame  
> edit - right selection side to cursor  
> edit - copy  
> edit - paste  
> transport - locate selection  
> transport - locate next event  
> edit - left selection side to cursor  
> transport - locators to selection  
> tool - select tool  
> process project logical editor - “your PLE script to select automation inside cycle” (see below)
> 
> –the PLE script:  
> media type equals automation  
> position inside cycle PPQ  
> //  
> function - select

thanks a lot!

---

<div class="post-metadata">

**Author:** ![Winter\_Rat](https://dub1.discourse-cdn.com/steinberg/user_avatar/forums.steinberg.net/winter_rat/32/217_2.png) [@Winter\_Rat](https://forums.steinberg.net/u/Winter_Rat)\
**Post date:** [April 16, 2013, 10:55am UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/11 "2013-04-16T10:55:17Z")

</div>

> [@lukasbrooklyn](#):
>
> in other words, i need to write a PLE script that selects the automation events inside the cycle, but only on the track for the one parameter you are trying to trim.

Why? Either way, You won’t edit all parameters at once. Let say, I wanna edit volume, but Macro selected pan events either, but when I move volume curve, my actions have no effect on the pan automation. So, why be bothered? 🙂

But, if in Prefs you’ve got “Track selection follows event selection” checked, it’ll be easy.

1. Edit → Select all on tracks

PLE:  
(Property \_\_\_\_\_\_Is set\_\_\_\_\_\_\_\_event is selected\_\_\_and  
Media Type is \_\_Equal\_\_\_\_\_\_\_\_Automation\_\_\_\_\_\_\_and  
Position\_\_\_\_\_\_\_Inside cycle\_\_\_\_\_\_PPQ \_\_\_\_\_\_\_\_\_\_\_\_).

But, if you don’t use “Track selection follows event selection”, i don’t know…yet. 🙂 But, sure, you can choose track manually.(but you need always remember to do that)

---

<div class="post-metadata">

**Author:** ![lukasbrooklyn](https://avatars.discourse-cdn.com/v4/letter/l/e95f7d/32.png) [@lukasbrooklyn](https://forums.steinberg.net/u/lukasbrooklyn)\
**Post date:** [April 17, 2013, 12:47pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/12 "2013-04-17T12:47:44Z")

</div>

> [@Winter Rat](#):
>
> > [@lukasbrooklyn](#):
> >
> > in other words, i need to write a PLE script that selects the automation events inside the cycle, but only on the track for the one parameter you are trying to trim.
> 
> Why? Either way, You won’t edit all parameters at once. Let say, I wanna edit volume, but Macro selected pan events either, but when I move volume curve, my actions have no effect on the pan automation. So, why be bothered? 🙂
> 
> But, if in Prefs you’ve got “Track selection follows event selection” checked, it’ll be easy.
> 
> 1. Edit → Select all on tracks
> 
> PLE:  
> (Property \_\_\_\_\_\_Is set\_\_\_\_\_\_\_\_event is selected\_\_\_and  
> Media Type is \_\_Equal\_\_\_\_\_\_\_\_Automation\_\_\_\_\_\_\_and  
> Position\_\_\_\_\_\_\_Inside cycle\_\_\_\_\_\_PPQ \_\_\_\_\_\_\_\_\_\_\_\_).
> 
> But, if you don’t use “Track selection follows event selection”, i don’t know…yet. 🙂 But, sure, you can choose track manually.(but you need always remember to do that)

thank you, finally got that to work.

there’s one area that could tighten this up even more. as it is, my macro is using ‘frame nudges’ to create neighbouring automation events as close as possible. this still produces ~30-45 ms gap between the adjacent automation events. i wondered if there is a way to nudge the transport in ticks using a macro / kc / PLE. i can easily nudge an event in ticks using PLE, but how would one do this with the cursor? (possibly using a workaround… an automation event nudged in ticks, then using the ‘locate selection’ command. oh well…)

---

<div class="post-metadata">

**Author:** ![BFred](https://avatars.discourse-cdn.com/v4/letter/b/8797f3/32.png) [@BFred](https://forums.steinberg.net/u/BFred)\
**Post date:** [April 18, 2013, 8:48pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/13 "2013-04-18T20:48:55Z")

</div>

I looks fantastic, but it doesn’t work here. Have revised every steps in the macro a dozen times.

It paste the automation to some ‘‘random’’ position.

Any idea what could cause that.

BTW I’m on Cubase 7.0.4

thanks

---

<div class="post-metadata">

**Author:** ![lukasbrooklyn](https://avatars.discourse-cdn.com/v4/letter/l/e95f7d/32.png) [@lukasbrooklyn](https://forums.steinberg.net/u/lukasbrooklyn)\
**Post date:** [April 18, 2013, 8:57pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/14 "2013-04-18T20:57:39Z")

</div>

> [@BFred](#):
>
> I looks fantastic, but it doesn’t work here. Have revised every steps in the macro a dozen times.
> 
> It paste the automation to some ‘‘random’’ position.
> 
> Any idea what could cause that.
> 
> BTW I’m on Cubase 7.0.4
> 
> thanks

not sure, working 100% now here on cubase 6.0.7; also tested as working in a nuendo 4 studio (though nuendo 4 doesn’t offer the new automation scaling possibilities introduced in c6)

(my c7 demo has expired and not planning on buying, it sucks for what i do, so i cannot test it).

---

<div class="post-metadata">

**Author:** ![distante](https://dub1.discourse-cdn.com/steinberg/user_avatar/forums.steinberg.net/distante/32/591_2.png) [@distante](https://forums.steinberg.net/u/distante)\
**Post date:** [April 18, 2013, 9:15pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/15 "2013-04-18T21:15:01Z")

</div>

> [@BFred](#):
>
> BTW I’m on Cubase 7.0.4

Wait, what? when did the 0.4 version come out?

---

<div class="post-metadata">

**Author:** ![steve](https://dub1.discourse-cdn.com/steinberg/user_avatar/forums.steinberg.net/steve/32/193789_2.png) [@steve](https://forums.steinberg.net/u/steve)\
**Post date:** [April 19, 2013, 2:02am UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/16 "2013-04-19T02:02:57Z")

</div>

There are a couple time travelers on the forum. Or there will be yesterday.

---

<div class="post-metadata">

**Author:** ![BFred](https://avatars.discourse-cdn.com/v4/letter/b/8797f3/32.png) [@BFred](https://forums.steinberg.net/u/BFred)\
**Post date:** [April 20, 2013, 7:16pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/17 "2013-04-20T19:16:30Z")

</div>

> [@distante](#):
>
> > [@BFred](#):
> >
> > BTW I’m on Cubase 7.0.4
> 
> Wait, what? when did the 0.4 version come out?

My bad. I mean 7.0.3

Sorry

---

<div class="post-metadata">

**Author:** ![BFred](https://avatars.discourse-cdn.com/v4/letter/b/8797f3/32.png) [@BFred](https://forums.steinberg.net/u/BFred)\
**Post date:** [April 20, 2013, 7:20pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/18 "2013-04-20T19:20:36Z")

</div>

> [@Bredo](#):
>
> > [@BFred](#):
> >
> > I looks fantastic, but it doesn’t work here. Have revised every steps in the macro a dozen times.
> > 
> > It paste the automation to some ‘‘random’’ position.
> > 
> > Any idea what could cause that.
> > 
> > BTW I’m on Cubase 7.0.4
> > 
> > thanks
> 
> I had to “tweak a bit” to get it right (in C6.5). I changed one line and removed three. Here is how the macro looks on my side:
> 
> edit - copy  
> edit - paste  
> transport - locate selection  
> transport - nudge +1 frame  
> edit - left selection side to cursor  
> transport - locate selection end  
> transport - nudge +1 frame  
> edit - right selection side to cursor  
> edit - copy  
> edit - paste  
> transport - locate selection  
> transport - locators to selection  
> tool - select tool  
> process project logical editor - “Your script” (see below)
> 
> –the PLE script:  
> media type equals automation  
> position inside cycle PPQ  
> //  
> function - select
> 
> Just make sure your PLE script is correct.
> 
> I will test on C7 soon. Maybe 😉

Thanks,

It almost worked. But the macro won’t create the 2 events at start and end borders, I think. Maybe C7 is different… Or it’s a question of OsX/Windows version. I will try to understand what’s the problem.

---

<div class="post-metadata">

**Author:** ![steve](https://dub1.discourse-cdn.com/steinberg/user_avatar/forums.steinberg.net/steve/32/193789_2.png) [@steve](https://forums.steinberg.net/u/steve)\
**Post date:** [April 20, 2013, 7:59pm UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/19 "2013-04-20T19:59:41Z")

</div>

> [@BFred](#):
>
> It almost worked.

I am finding the same.

When I get the time or the need I will try to find a way for it to work.

I have an idea of how to paste in the points, but it’s kludgy, and not even working yet.

---

<div class="post-metadata">

**Author:** ![Winter\_Rat](https://dub1.discourse-cdn.com/steinberg/user_avatar/forums.steinberg.net/winter_rat/32/217_2.png) [@Winter\_Rat](https://forums.steinberg.net/u/Winter_Rat)\
**Post date:** [April 21, 2013, 11:14am UTC](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383/20 "2013-04-21T11:14:54Z")

</div>

Hi,  
in C7 everything works as expected with the original macro from **lukasbrooklyn**. His macro has “transport - nudge +1 frame” string doubled, you can skip 1.

BTW, here’s another Macro to do the same job, but operating with seconds not frames.

[![](http://s019.radikal.ru/i604/1304/b3/10068ff6d3d8.jpg)](http://www.radikal.ru)

The last string refers to PLE Macro form the previous version.  
But sorry guys, nothing comes for free, to use this Macro you’ll need to set your Ruler Display Format to Seconds and set Grid Type to 1ms manually. When all your editing is done you can switch your Ruler Display Format back (if needed). I know it takes time and clicks, but sometimes it’s much easier, than putting all those new nodes around the range of automation you want to select and edit.

Cheers

[Next page](https://forums.steinberg.net/t/cubase-ninja-pro-tools-style-trim-automation-macro/627383.md?page=2)
