SilkTone
Max Output Level: -59.5 dBFS
- Total Posts : 1566
- Joined: 2003/11/10 17:41:28
- Status: offline
Silly question: Is there a command to join adjacent MIDI notes?
I've never had to do this before so I'm at a bit of a loss, but it seems there should be a way...? Let's say I have many MIDI notes that are split in various places but are butting up right against each other. Is there a way to select a bunch of clips and join all adjacent MIDI notes in one go? I can do this manually one note at a time but that would be very time consuming since there are many. Before: |---------||--------| |-----------| After: |-------------------| |-----------|
|
jackson white
Max Output Level: -85 dBFS
- Total Posts : 283
- Joined: 2008/02/19 21:35:13
- Location: BOS
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 12:45:21
(permalink)
What is your definition of "adjacent"? The time between the end of a note and the start of the next one? The time between the start of a note and the start of the next one? Measured in ticks (per quarter note)? I assume you mean the same pitch.
-------------------- Some pieces of wood with wires and bits of metal stuck in them, silicon and plastic
|
scook
Forum Host
- Total Posts : 24146
- Joined: 2005/07/27 13:43:57
- Location: TX
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 12:50:15
(permalink)
I don't know if a way exists today but it could be scripted. UNDUPE.CAL would get you most of the way there.
|
SilkTone
Max Output Level: -59.5 dBFS
- Total Posts : 1566
- Joined: 2003/11/10 17:41:28
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 12:59:23
(permalink)
Jackson, Yes same pitch. The next note starts on or within a few ticks of the previous note's end. As if you previously split the note, but now want to join them back again. Scook, I was looking through the CAL scripts but didn't find an exact match. So yea I could try your suggestion and modify the UNDUP.CAL one. Been a while since I worked with CAL scripts...
|
Anderton
Max Output Level: 0 dBFS
- Total Posts : 14070
- Joined: 2003/11/06 14:02:03
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 13:24:15
(permalink)
You can join MIDI notes easily in the step sequencer. Convert the clip to a step-sequenced one (you can do this quantized or retain offsets, check the documentation). Ctrl-drag across the notes you want to join, then bounce the step-sequenced clip to itself. If you open this clip in the piano roll view, the notes will be joined.
|
SilkTone
Max Output Level: -59.5 dBFS
- Total Posts : 1566
- Joined: 2003/11/10 17:41:28
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 13:44:21
(permalink)
Anderton You can join MIDI notes easily in the step sequencer. Convert the clip to a step-sequenced one (you can do this quantized or retain offsets, check the documentation). Ctrl-drag across the notes you want to join, then bounce the step-sequenced clip to itself. If you open this clip in the piano roll view, the notes will be joined. Craig, thanks excellent tip! I'll try it.
|
Anderton
Max Output Level: 0 dBFS
- Total Posts : 14070
- Joined: 2003/11/06 14:02:03
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 13:58:26
(permalink)
I know it's a workaround, but I often switch between step sequencer and piano roll view for various reasons. I had always thought the step sequencer was, well, a "step sequencer" - but it's a powerful, alternate way to work with MIDI data once you find out its particular talents.
|
MondoArt
Max Output Level: -86 dBFS
- Total Posts : 226
- Joined: 2011/11/29 18:51:10
- Location: Toronto
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 15:45:37
(permalink)
Why not just delete the second note, then extend the first one to the same end point?
Neel Songwriter/Producer neelmodi.com Sonar Platinum | Intel i5 | Windows 10 Home | Focusrite Scarlett 2i4 | Akai Advance 61 | NI Komplete 10
|
MarioD
Max Output Level: -72 dBFS
- Total Posts : 901
- Joined: 2006/04/15 15:59:50
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 17:14:23
(permalink)
☄ Helpfulby mettelus 2014/10/04 23:03:54
Another method is in the piano roll view click on the draw icon in the smart tool window, put the cursor near the end of the first note, hold down the left mouse button and drag the cursor over the notes that you want to connect.
The reason people say the vinyl sounds better is because the music was better. Sonar Platinum, Intel i7 –2600 CPU @ 3.2 GHz, 16 GB ram, 2x2TB internal drives and 1 1TB internal drive, Radeon HD 5570 video card, HP 25" monitor, Roland Octa Capture, MOTU Midi Express 128, Win 10 Pro www.soundcloud.com/Mario_Guitar
|
SilkTone
Max Output Level: -59.5 dBFS
- Total Posts : 1566
- Joined: 2003/11/10 17:41:28
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 18:11:25
(permalink)
MondoArt Why not just delete the second note, then extend the first one to the same end point? Because there are A lot of them and it would be very time consuming as stated earlier. MarioD Another method is in the piano roll view click on the draw icon in the smart tool window, put the cursor near the end of the first note, hold down the left mouse button and drag the cursor over the notes that you want to connect. This might be a bit easier but still time consuming. Thanks for the tip, I didn't know about that one.
post edited by SilkTone - 2014/10/04 18:19:55
|
Anderton
Max Output Level: 0 dBFS
- Total Posts : 14070
- Joined: 2003/11/06 14:02:03
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 19:59:13
(permalink)
MarioD Another method is in the piano roll view click on the draw icon in the smart tool window, put the cursor near the end of the first note, hold down the left mouse button and drag the cursor over the notes that you want to connect.
Another reason to love this forum  Jeez, you think I'd remember that there's a Glue tool in Sonar!! SilkTone, I think you'll find this is a very fast way to work. You don't have to drag the end of the first note precisely, just land it somewhere in the second note and they glue together. I think you'd find this faster than using the step sequencer.
|
mudgel
Max Output Level: 0 dBFS
- Total Posts : 12010
- Joined: 2004/08/13 00:56:05
- Location: Linton Victoria (Near Ballarat)
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 21:22:25
(permalink)
The depth of knowledge here never ceases to amaze me. Excellent!
Mike V. (MUDGEL) STUDIO: Win 10 Pro x64, SPlat & CbB x64, PC: ASUS Z370-A, INTEL i7 8700k, 32GIG DDR4 2400, OC 4.7Ghz. Storage: 7 TB SATA III, 750GiG SSD & Samsung 500 Gig 960 EVO NVMe M.2. Monitors: Adam A7X, JBL 10” Sub. Audio I/O & DSP Server: DIGIGRID IOS & IOX. Screen: Raven MTi + 43" HD 4K TV Monitor. Keyboard Controller: Native Instruments Komplete Kontrol S88.
|
mettelus
Max Output Level: -22 dBFS
- Total Posts : 5321
- Joined: 2005/08/05 03:19:25
- Location: Maryland, USA
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 21:26:05
(permalink)
This is a nice tip! Audio-to-MIDI conversion often splits notes on me as described in the OP, so this will come in very handy.
ASUS ROG Maximus X Hero (Wi-Fi AC), i7-8700k, 16GB RAM, GTX-1070Ti, Win 10 Pro, Saffire PRO 24 DSP, A-300 PRO, plus numerous gadgets and gizmos that make or manipulate sound in some way.
|
Anderton
Max Output Level: 0 dBFS
- Total Posts : 14070
- Joined: 2003/11/06 14:02:03
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/04 21:42:21
(permalink)
I was hoping there would be a "forum-knowledge-to-brain-dump" function in Sonar X4. Noel said maybe Sonar X37.
|
SilkTone
Max Output Level: -59.5 dBFS
- Total Posts : 1566
- Joined: 2003/11/10 17:41:28
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/05 14:14:43
(permalink)
Yea the glue tool is very useful, thanks Mario for pointing that one out. It is the easiest but unfortunately didn't solve my problem as I have too many to fix up. Craig I tried the step sequencer tip but the clip I dragged into it covers the full song, and the step sequencer shortened it to just a few bars. Maybe there is a setting I can use to make it accept the full 100+ measures in one go, but at the end of the day it is still a manual process to join the notes so the glue tool turns out to be better for this purpose. But I must confess the original problem was of my own making. I made a "chord sequencer" plugin that I use to enter all of my chords. It is just easier that way because now I can feed the chords into multiple VSTs, like Real Guitar, Real Strat, or just a simple string synth to use as a backing while sketching out a song. Anyway I'm adding a "Join Adjacent Notes" option to it that will automatically do what I need and sustain common notes from one to the next chord. This will solve my problem for both feeding directly from the chord sequencer into other VSTs, or when dragging the MIDI clip onto a track. But yea this forum never ceases to teach one about new tips and tricks...
|
Anderton
Max Output Level: 0 dBFS
- Total Posts : 14070
- Joined: 2003/11/06 14:02:03
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/05 14:52:04
(permalink)
SilkTone Craig I tried the step sequencer tip but the clip I dragged into it covers the full song, and the step sequencer shortened it to just a few bars. Maybe there is a setting I can use to make it accept the full 100+ measures in one go.
No, there isn't. The step sequencer does a maximum of 64 beats with 16 steps per beat.
|
scook
Forum Host
- Total Posts : 24146
- Joined: 2005/07/27 13:43:57
- Location: TX
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/05 14:57:31
(permalink)
Here is a script for joining notes where join candidates are sequential note events and the second note starts immediately after the first note. Scripting a solution gets a little messy when notes of different pitches start overlapping in time. ;;; joinNotes.CAL;;;;;; joins adjacent notes;;; ;;; ---------------------------------------------------------------------;;; Prolog;;;(do ; flag used to control write ; 0 = initialize required ; 1 = write required (int writeEvent 0) ; event variables (dword etime 0) ; event time (int echan 0) ; event channel (int nkey -1) ; note key (int nvel 0) ; note velocity (dword ndur 0) ; note duration);;; ---------------------------------------------------------------------;;; Body;;;(do (if (== Event.Kind NOTE) (if (== writeEvent 0) (do (= etime Event.Time) (= echan Event.Chan) (= nkey Note.Key) (= nvel Note.Vel) (= ndur Note.Dur) (= writeEvent 1) (delete) ) (if (&& (== Note.Key nkey) (== Event.Time (+ etime ndur))) (do (delete) (= ndur (+ ndur Note.Dur)) ) (do (delete) (insert etime echan NOTE nkey nvel ndur) (= etime Event.Time) (= echan Event.Chan) (= nkey Note.Key) (= nvel Note.Vel) (= ndur Note.Dur) ) ) ) ));;; ---------------------------------------------------------------------;;; Epilog;;;(if (== writeEvent 1) (insert etime echan NOTE nkey nvel ndur))
post edited by scook - 2014/10/05 15:18:19
|
SilkTone
Max Output Level: -59.5 dBFS
- Total Posts : 1566
- Joined: 2003/11/10 17:41:28
- Status: offline
Re: Silly question: Is there a command to join adjacent MIDI notes?
2014/10/05 15:16:41
(permalink)
scook, Interesting, I'll take a look. Thanks.
|