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

Reply via email to