lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re:Combine these segments for same score


From: Flaming Hakama by Elaine
Subject: Re:Combine these segments for same score
Date: Fri, 21 Dec 2018 17:06:53 -0800



---------- Forwarded message ----------
From: Reggie <address@hidden>
To: address@hidden
Cc: 
Bcc: 
Date: Fri, 21 Dec 2018 15:08:32 -0700 (MST)
Subject: Re: Re:Combine these segments for same score
Flaming Hakama by Elaine wrote
> Yes, you can use tags for segmenting large works into smaller chunks.
>
> And it is possible to use them for other things as well.  Besides
> segmenting the work, I use them for MIDI vs PDF, as well as Score vs Parts
> (vs Lead Sheet), and sometimes for instrument-specific differences (in
> instrumental doubled or transposed parts), all at the same time.
>
> This is something I practice.  I have a script that will create the
> necessary files for the project that will compile a score and parts that
> can be built into a blank project.  It relies on some templates, plus a
> list of instruments.  It works fine enough that I haven't had to look for
> another solution.
> https://github.com/flaminghakama/lilypond-project-template
>
> Like any of the solutions discussed on the list, this is not a
> one-size-fits-all bullet and requires wrangling with some decisions about
> how you want to structure your content.  You will likely have to
> deconstruct some of what you already have to work in any templating
> system.  It is also somewhat of an iterative process, since you need to
> start with a template of the global definitions and timings, before
> setting
> up the template used to generate the instrument-specific files of musical
> content.
>
> In any case, your pain is felt.  But it is possible.  I generally do
> scores
> of 9-12 staves at 200-400 measures and it took me quite some time to
> arrive
> at a solution that works.
>
>
> HTH,
>
> Elaine Alt
> 415 . 341 .4954                                           "*Confusion is
> highly underrated*"

> elaine@

> Producer ~ Composer ~ Instrumentalist
> -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
>
> _______________________________________________
> lilypond-user mailing list

> lilypond-user@

> https://lists.gnu.org/mailman/listinfo/lilypond-user

I am intrigued. How does one use the tag system for concatenating sections
of the same piece for easy working and compiling speed during edit phase?
Please, can you provide some code showing how to use tags like this I have
only seen tags used for differences in music of the score for parts and so
on.

Tags for combining sections?!


So, here is the basic approach.

You need to divide up the entire piece in to secions, each enclosed in a tag.

These tags need to be in a few places, basically any music or structural
things.  In this example, this includes global info, and then two instruments.

Besides the tagged sections, we'll have tags for PDF vs MIDI, and Score vs Part.


\version "2.18.2"

global = {
    \key d \major
    \tempo "Allegro"
    \tag SegmentA {
        \time 3/4
        \mark "A"
        s2.*8
        \bar "||"
        %  Here is something that will only be in the score, and not the parts
        \tag #'Score { \pageBreak }
    }
    \tag SegmentB {
        \time 4/4
        \mark "B"
        s1*8
        \bar "|."
    }
}

violin = {
    \tag SegmentA \relative c'' {
        % Here we have different content for PDF vs MIDI
        \tag #'PDF {
            d2.\startTrillSpan d\stopTrillSpan
        }
        \tag #'MIDI {
            d16 e d e  d e d e  d e d e
            d2.
        }
        d2. d  d d d d
    }
    \tag SegmentB \relative c'' {
        e1 e e e e e e e
    }
}

bassoon = {
    \tag SegmentA {
        R2.*8
    }
    \tag SegmentB {
        c1 d e f 
        %  Here we have content that is only for the part, not the score
        \tag #'Part { \break }
        g a b c
    }
}

% The Visual Score
\book {
    \bookOutputSuffix "Full-Score"
    \score {
        \header {
            piece = "Full Score, with score-only page break"
        }   
        \keepWithTag #'(PDF Score
            SegmentA
            SegmentB
        ) <<
            \new Staff <<
                \global
                \violin
            >>
            \new Staff <<
                \clef bass
                \bassoon
            >>
        >>
        \layout {}
    }
}

% The Audio Score
\book {
    \bookOutputSuffix "Full-Score"
    \score {
        \header {
            piece = "MIDI score, with written-out trill"
        }   
        \keepWithTag #'(MIDI Score
            SegmentA
            SegmentB
        ) <<
            \new Staff <<
                \global
                \violin
            >>
            \new Staff \bassoon
        >>
        \midi {}
    }
}

% The parts
\book {
    \bookOutputSuffix "Violin"
    \score {
        \header {
            piece = "Violin Part, with normal trill and no page break"
        }   
        \keepWithTag #'(PDF Part
            SegmentA
            SegmentB
        ) \new Staff <<
            \global
            \violin
        >>
        \layout {}
    }
}

\book {
    \bookOutputSuffix "Bassoon"
    \score {
        \header {
            piece = "Bassoon Part, with part-only line break"
        }   
        \keepWithTag #'(PDF Part
            SegmentA
            SegmentB
        ) \new Staff <<
            \global
            \clef bass
            \bassoon
        >>
        \layout {}
    }
}

%{
    The main point here is that you can limit what is compiled by commenting out
    all the other section tags.  Here, we only compile segment B, by commenting
    out SegmentA.
%}

\book {
    \bookOutputSuffix "Full-Score-Segment-B"
    \score {
        \header {
            piece = "Full Score, but only section B"
        }   
        %{    
            There are newer syntaxes available for specifying the list of tags,
            but I suggeset using this old syntax since it supports this approach
            of commenting out individual lines.
        %}
        \keepWithTag #'(PDF Score
            %SegmentA
            SegmentB
        ) <<
            \new Staff <<
                \global
                \violin
            >>
            \new Staff <<
                \clef bass
                \bassoon
            >>
        >>
        \layout {}
    }
}

HTH,



Elaine Alt
415 . 341 .4954                                           "Confusion is highly underrated"
address@hidden
Producer ~ Composer ~ Instrumentalist
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-


reply via email to

[Prev in Thread] Current Thread [Next in Thread]