lilypond-user
[Top][All Lists]
Advanced

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

Re: dynamics seperatate from the notes entry


From: Karl Hammar
Subject: Re: dynamics seperatate from the notes entry
Date: Tue, 1 Jan 2013 16:19:44 +0100 (CET)

David Kastrup:
> address@hidden (Karl Hammar) writes:
...
> > This looks like a bug.
> >
> > \version "2.17.10"
> >
> > Ms = \relative a' { c4 c c c | }
> > Ds = \relative a' { s\p s s\f s | }
> > Ma = \relative a' { c4\p c c\f c }
> >
> > \score {
> >   <<
> >     \new Staff \relative a' { c4\p c c\f c | << \Ms \Ds >> | }
> >     \new Staff { \Ma | << \Ms \Ds >> | }
> >   >>
> > }
> >
> > The difference between above two staffs is that in the top staff
> > the music is written out, and in the bottom the music comes from a
> > variable.
> 
> Uh, no?  The difference is that in the top staff, there are isolated
> note events starting an implicit Voice, while in the bottom staff, there
> is no isolated event but rather a sequential music expression that gets
> its _own_ \new Voice ending at the closing brace.  If you had written
> wrote
> 
> { { c4\p c c\f c } | << \Ms \Ds >> }
> 
> above, you'd have gotten the same.

Ok, if I use

    \new Staff { \relative a' { c4\p c c\f c } | << \Ms \Ds >> | }
    \new Staff { \Ma | << \Ms \Ds >> | }

I get two same-looking staffs.

> Note that | is just a barcheck and

Known.

> not an event starting (or maintaining) a new voice.  So \Ms starts its
> own, new voice, and then \Ds does as well.

Is there any way or tool to identify what voices gets created and their
names, or rather it would be nice to get a optional warning when implicit
voices are created so I can track them down, they seem to be a pain ?

> Of course, if you wrote \new Voice everywhere where you write \new Staff
> now, LilyPond would have put everything into the same Voice either way.

Ok, if I write

    \new Staff \context Voice = Vs { \relative a' { c4\p c c\f c | << \Ms \Ds 
>> | } }
    \new Staff \context Voice = Va { \Ma | << \Ms \Ds >> | }

I get what I want.

///

So from what I understand, to make \Ms and \Ds to show up "nice", they
have to be in the same voice. Which

Ms = \context Voice = Va \relative a' { c4 c c c | }
Ds = \context Voice = Va \relative a' { s\p s s\f s | }

\score \new Staff  { << \Ms \Ds >> }

exemplifies, and the example in the previous mail is then just
"user error".

///

In Documentation/out-www/internals.pdf / 2.1.29 Voice:

 Corresponds to a voice on a staff. This context handles the
 conversion of dynamic signs, stems, beams, super- and subscripts,
 slurs, ties, and rests.

 You have to instantiate this explicitly if you want to have
 multiple voices on the same staff.

This wording does not sound true if there are a lot of implicit voice
creation (in my mind only "\new Voice" is explicit).

Searching for "implicit voice" in notation.pdf / learning.pdf doesn't
yield anything.

So by guessing what creates voices are:

 \new Voice { }
 << { } { } >>
 << { } \\ { } >>
 in a Staff a voice is implcitly created in cases like \new Staff { c }

Any more cases?

Regards,
/Karl Hammar

-----------------------------------------------------------------------
Aspö Data
Lilla Aspö 148
S-742 94 Östhammar
Sweden
+46 173 140 57





reply via email to

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