lilypond-user
[Top][All Lists]
Advanced

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

Re: missing glissando features (bugs?)


From: Neil Puttock
Subject: Re: missing glissando features (bugs?)
Date: Wed, 13 May 2009 23:13:08 +0100

2009/5/11 Marc Hohl <address@hidden>:

>    (if (and (= left-staff-position right-staff-position)
>             (< (ly:pitch-semitones right-pitch) (ly:pitch-semitones
> left-pitch)))
>                -1
>                 1 )))

This will apply an extra-dy of 1 for glissandos which aren't on the
same staff-position.

> Here I'm stuck, 'cause when I override the value for extra-dy manually, as
> in
>
> dytest = \relative c {
>  \set TabStaff.minimumFret = #2
>  \override Glissando #'extra-dy = #0
>  c4 \glissando cis \glissando c2
> }
>
> \score {
>   \new TabStaff { \clef "tab" \dytest } }
>           the glissando line doesn't look as expected, it is parallel to the
> staff lines and therefore
> invisible. So, strange as it seems, the value "1" must be right here.

The default value for 'extra-dy is set to 0.75 for all glissandos,
even if they're on different lines; see the context definition in
engraver-init.ly.

Though I suggested using cond/else, it's probably easier to use nested
if clauses: if the staff-positions are equal, compare the pitches,
otherwise return a default value of 0.

     (if (= left-staff-position right-staff-position)
         (if (< (ly:pitch-semitones right-pitch) (ly:pitch-semitones 
left-pitch))
             -1
             1)

         ;; not on same staff-position -> no extra-dy
         0))

> Just for the record: I think it would be reasonable to move the
> glissando::calc-tab-extra-dy
> call to tablature.ly, so all files are backwards compatible and tablature
> users can profit from
> the nicer glissando lines :-)

It would make an excellent addition to the file.

Regards,
Neil




reply via email to

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