lilypond-user
[Top][All Lists]
Advanced

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

Re: Bar line check is wrong with partial note and voltas


From: David Wright
Subject: Re: Bar line check is wrong with partial note and voltas
Date: Mon, 12 Oct 2020 21:56:30 -0500
User-agent: Mutt/1.10.1 (2018-07-13)

On Mon 12 Oct 2020 at 14:46:43 (-0700), Knute Snortum wrote:
> On Mon, Oct 12, 2020 at 10:03 AM Aaron Hill <lilypond@hillvisions.com> wrote:
> > On 2020-10-12 9:56 am, Knute Snortum wrote:
> > >
> > > I think I've run into a bug.  It's hard to explain so I will post the
> > > MWE (it's as minimal as I could make it):
> > >
> > > %%% Start
> > > \version "2.20.0"
> > >
> > > rightHand = \relative c' {
> > >   \partial 4 c4
> > >   c4 c c
> > >
> > >   \repeat volta 2 {
> > >     c4 |
> > >     c4 c c c |
> > >   }
> > >   \alternative {
> > >     { c4 c c }
> > >     { c4 c c c }
> > >   }
> > >
> > >   c1 |
> > > }
> > >
> > > \score {
> > >   \new Staff \rightHand
> > >   \midi {
> > >   }
> > > }
> > > %%% End
> > >
> > > The c1 at the end of the music produces a bar line check warning.  It
> > > only happens when creating a MIDI file. It only happens when the volta
> > > is in the middle of the measure.  It only happens when an alternate
> > > ending doesn't contain a full measure of notes.
> > >
> > > Any thoughts?  I really appreciate you guys.
> >
> > Don't you need to \unfoldRepeats when doing MIDI output?
> >
> > %%%%
> > \score {
> >    \new Staff \unfoldRepeats \rightHand
> >    \midi { }
> > }
> > %%%%
> 
> Thanks, Aaron Hill.  The only problem is this messes up my \barNumberChecks
> 
> %%% Start
> \version "2.20.0"
> 
> rightHand = \relative c' {
>   \partial 4 c4
>   c4 c c
> 
>   \repeat volta 2 {
>     c4 |
>     c4 c c c |
>   }
>   \alternative {
>     { c4 c c }
>     { c4 c c c }
>   }
> 
>   \barNumberCheck 5
>   c1 |
> }
> 
> \score {
>   \new Staff \rightHand
> }
> 
> \score {
>   \new Staff \unfoldRepeats \rightHand
>   \midi {
>   }
> }
> %%% End

Your \barNumberCheck, as you placed it, should be expecting 4 or 6,
as in the attached, but not 5. A \barNumberCheck placed at the
barline should be set to the number of the next measure, not the
previous one.

However, I agree that LP's a bit messy when you generate MIDI with
folded repeats, which is something I regularly do in order to
proof-read by ear. In this case, you get the barcheck shown by
your version at the top of the quote above.

My workaround is the same as previously: generate the MIDI first,
then the score. My \barNumberChecks are naturally set to agree with
the printed/folded bar numbers, so all the noise goes into the
MIDI part of the console log, and the \layout part should be clean.

Cheers,
David.

Attachment: knute3.ly
Description: Text document

Attachment: knute3.png
Description: PNG image


reply via email to

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