Old 11-12-2017, 11:22 AM   #1
davesmith3141
Human being with feelings
 
Join Date: Nov 2014
Posts: 7
Default Pianoroll Text Events to Lyric Events

Hello,

I'm just starting to discover the notation feature. In the past, I've added lyrics as text events in the pianoroll view. I was hoping the events would show up in the notation but it doesn't. Do I have to rekey all the lyrics in or is there some easier way to get that from the midi data and have it show up in the notation?

Thanks very much for your help!
davesmith3141 is offline   Reply With Quote
Old 11-13-2017, 03:03 PM   #2
juliansader
Human being with feelings
 
Join Date: Jul 2009
Posts: 3,714
Default

Good question. It seems that REAPER's built-in Properties dialog box for text events only applies to the first selected event, so it can't be used to change the text type of multiple events.

(Only text events with type "Lyrics" will show up in the notation view.)

The following quick script will change selected text events in the active take to lyrics:

Code:
take = reaper.MIDIEditor_GetTake(reaper.MIDIEditor_GetActive())
index = reaper.MIDI_EnumSelTextSysexEvts(take, -1)
while index > -1 do
    _, _, _, _, texttype, _ = reaper.MIDI_GetTextSysexEvt(take, index, nil, nil, nil, 0, "")
    if texttype == 1 then -- 1 = type "Text event"
        reaper.MIDI_SetTextSysexEvt(take, index, nil, nil, nil, 5, "", true) -- 5 = type Lyrics
    end
    index = reaper.MIDI_EnumSelTextSysexEvts(take, index)
end
reaper.Undo_OnStateChange2(0, "Convert text events to lyrics")
juliansader is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 04:01 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.