Re: possible bug: \change Staff and beam collision
On Nov 2, 2014, at 8:40 PM, Gilberto Agostinho gilbertohasn...@gmail.com wrote: Hello all, Please have a look on the following code: \version 2.19.15 \new PianoStaff \new Staff = up { \override Score.Beam.damping = 3 \stemUp a'8 \ottava #1 a''' \ottava #0 a' a, } \new Staff = down { \clef bass s2 } \new PianoStaff \new Staff = up { \override Score.Beam.damping = 3 \stemUp a'8 \ottava #1 a''' \ottava #0 a' \change Staff = down a, } \new Staff = down { \clef bass s2 } Which produces: http://lilypond.1069038.n5.nabble.com/file/n168324/11.png As you can see, without changing staff the ottava position is high enough not to collide with the beam, but when changing staff the ottava position gets lower (!) and collides with the beam. Anyone know any workaround for this problem? Best, Gilberto This is a persistent issue in LilyPond development - there was some work on it in course a couple years ago that has since been put on hold but I hope to pick it back up one day. The gist of the problem (and others like it) is that, because the beam is cross staff, the layout engine does not know where it will be placed because it does not know how far apart vertically the notes are until final page spacing is done. That means that all objects that depend on the beam for placement (such as the ottava) ignore it when being placed and, as a result, you get collisions. I know that Keith has several cross-staff-related workarounds in his piano scores. Sorry I can’t be of more help, but it is not an easy issue. Cheers, MS ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: possible bug: \change Staff and beam collision
On Nov 2, 2014, at 8:40 PM, Gilberto Agostinho gilbertohasn...@gmail.com wrote: Hello all, Please have a look on the following code: \version 2.19.15 \new PianoStaff \new Staff = up { \override Score.Beam.damping = 3 \stemUp a'8 \ottava #1 a''' \ottava #0 a' a, } \new Staff = down { \clef bass s2 } \new PianoStaff \new Staff = up { \override Score.Beam.damping = 3 \stemUp a'8 \ottava #1 a''' \ottava #0 a' \change Staff = down a, } \new Staff = down { \clef bass s2 } Which produces: http://lilypond.1069038.n5.nabble.com/file/n168324/11.png As you can see, without changing staff the ottava position is high enough not to collide with the beam, but when changing staff the ottava position gets lower (!) and collides with the beam. Anyone know any workaround for this problem? Best, Gilberto This is a persistent issue in LilyPond development - there was some work on it in course a couple years ago that has since been put on hold but I hope to pick it back up one day. The gist of the problem (and others like it) is that, because the beam is cross staff, the layout engine does not know where it will be placed because it does not know how far apart vertically the notes are until final page spacing is done. That means that all objects that depend on the beam for placement (such as the ottava) ignore it when being placed and, as a result, you get collisions. I know that Keith has several cross-staff-related workarounds in his piano scores. Sorry I can’t be of more help, but it is not an easy issue. Cheers, MS ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: possible bug: \change Staff and beam collision
On Nov 2, 2014, at 8:40 PM, Gilberto Agostinho gilbertohasn...@gmail.com wrote: Hello all, Please have a look on the following code: \version 2.19.15 \new PianoStaff \new Staff = up { \override Score.Beam.damping = 3 \stemUp a'8 \ottava #1 a''' \ottava #0 a' a, } \new Staff = down { \clef bass s2 } \new PianoStaff \new Staff = up { \override Score.Beam.damping = 3 \stemUp a'8 \ottava #1 a''' \ottava #0 a' \change Staff = down a, } \new Staff = down { \clef bass s2 } Which produces: http://lilypond.1069038.n5.nabble.com/file/n168324/11.png As you can see, without changing staff the ottava position is high enough not to collide with the beam, but when changing staff the ottava position gets lower (!) and collides with the beam. Anyone know any workaround for this problem? Best, Gilberto This is a persistent issue in LilyPond development - there was some work on it in course a couple years ago that has since been put on hold but I hope to pick it back up one day. The gist of the problem (and others like it) is that, because the beam is cross staff, the layout engine does not know where it will be placed because it does not know how far apart vertically the notes are until final page spacing is done. That means that all objects that depend on the beam for placement (such as the ottava) ignore it when being placed and, as a result, you get collisions. I know that Keith has several cross-staff-related workarounds in his piano scores. Sorry I can’t be of more help, but it is not an easy issue. Cheers, MS ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: possible bug: \change Staff and beam collision
Hi Mike, Thanks for your reply. Mike Solomon wrote This is a persistent issue in LilyPond development - there was some work on it in course a couple years ago that has since been put on hold but I hope to pick it back up one day. I totally understand it. Mike Solomon wrote I know that Keith has several cross-staff-related workarounds in his piano scores. Sorry I can’t be of more help, but it is not an easy issue. Thanks anyway, I will see if I find some interesting snippet by Keith then. My case is always complicated though, my main work is with algorithmically generated music and so I always need to either automatize a solution or completely forget about it and approach the problem of notation from a different point of view (manual tweaking isn't an option for what I do). Best, Gilberto -- View this message in context: http://lilypond.1069038.n5.nabble.com/possible-bug-change-Staff-and-beam-collision-tp168324p168329.html Sent from the User mailing list archive at Nabble.com. ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: possible bug: \change Staff and beam collision
Gilberto Agostinho gilbertohasnofb at gmail.com writes: but when changing staff the ottava position gets lower (!) and collides with the beam. LilyPond allows you to beam to any other staff, so in general that beam might have to go up and cross the ottava bracket, while the bracket must stay with the staff. This is not likely with ottava brackets but cross-staff beams and their stems sometimes need to cross similar spanning structures. The code is so far not sophisticated enough to look ahead to staff layout when placing the ottava on its home staff, so assumes the cross-staff beam might have to cross it. Logically we should have a setting \override Staff.OttavaBracket.cross-staff = #ly:side-position-interface::calc-cross-staf to tell Lilypond she may move the OttavaBracket along with the beam but when I give LilyPond permission this way, she does not move the beam. My case is always complicated though, my main work is with algorithmically generated music and so I always need to either automatize a solution or completely forget about it and approach the problem of notation from a different point of view (manual tweaking isn't an option for what I do). I have no better suggestion. The manual tweak is simple, though, \once\override Staff.OttavaBracket.staff-padding = #6 and Lilypond makes it easy to put overrides in a separate expression { s1*54 \overrideThis} { s1*32 s2 \overrideThat} ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user
Re: possible bug: \change Staff and beam collision
Hi Keith, Thanks for the detailed explanation, I think I understand the situation well now. Keith OHara wrote I have no better suggestion. The manual tweak is simple, though, \once\override Staff.OttavaBracket.staff-padding = #6 Thanks anyway. Unfortunately my case of avoiding manual tweaks is not simple laziness: I work with generative music, which means that I will give the performers a computer program rather than a score, and I will let them generate a new version of a work by themselves. This means that I have absolutely no chances of ever tweaking that .ly file. Nevertheless, I am trying to play around with staff-padding but the results are not very good. Sometimes the ottavas are way too high, sometimes the collision problem appears again. Thanks a lot for your reply, I really appreciate it. Best, Gilberto -- View this message in context: http://lilypond.1069038.n5.nabble.com/possible-bug-change-Staff-and-beam-collision-tp168324p168337.html Sent from the User mailing list archive at Nabble.com. ___ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user