[prev in list] [next in list] [prev in thread] [next in thread] 

List:       lilypond-user
Subject:    Re: Is there a way to get a "round" to play in the MIDI without making several staggered identical v
From:       "H. S. Teoh" via LilyPond user discussion <lilypond-user () gnu ! org>
Date:       2023-09-20 23:03:24
Message-ID: ZQt6PEjyROuwQXaY () qfbox ! info
[Download RAW message or body]

On Wed, Sep 20, 2023 at 09:37:27AM -0400, Kevin Cole wrote:
> I'm not quite sure how to ask the question. 
> Is there a way to play the same melody as different voices with different
> time offsets -- i.e. without duplicating it and adding rests at the
> beginnings of the duplicates? (I only want it in the MIDI part, as the
> printed part would only need to display the basic melody once.)

Assign the music to a variable, and reuse it multiple times:

	myMusic = {
		... % music notes here
	}

	% Printed score
	\score {
		\new Staff {
			\myMusic
		}
		\layout {}
	}

	% MIDI
	\score {
		<<
			\new Staff {
				\myMusic
			}
			\new Staff {
				R1	% whatever time offset you want here
				\myMusic
			}
			\new Staff {
				R1*2	% deeper time offset
				\myMusic
			}
		>>
		\midi {}
	}


T

-- 
"The whole problem with the world is that fools and fanatics are always so certain of \
themselves, but wiser people so full of doubts." -- Bertrand Russell. "How come he \
didn't put 'I think' at the end of it?" -- Anonymous


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic