Am 21. Juni 2015 09:24:48 MESZ, schrieb musicus <tomtom-ilm...@web.de>: >Dear all, > >In my last project I learned that sometimes you have to tweak a lot of >Slurs, Ties, etc. to get a satisfying result. >Of course, in many cases the \shape #'() Slur function helps a lot. >My problem with this function is the dependency on Lilyponds automatic >output. >If I want to change the paper-size or the staffsize, for example, the >calculation of the curves in the automatic output changes >and many of my tweaks are useless. >You can always use tags to differentiate between various paper >settings, >but nevertheless you have to find the correct values again and again. >Additionally you have to engrave first to get an impression of the >standard output, so that you can guess your \shape values. > >Because of this points I wondered if you could just use a function >relative to the "musical" anchor points of a curve (in most cases the >NoteHead, i would guess). >\override control-points is relative to the center Staff-Line, but in >many cases the center line is too far away from the curve position, >which makes guessing a bit difficult. > >So, basically you need two things to get a good looking curve without >needing graphical feedback: > > >- offset relative to its anchor for start and end points > >- offset relative to the straight line between start and end point for >the two middle points >(that means you could ignore the rotation of a curve, which is already >given by start and end point) >-> you have to convert these "rotated" offsets to standard x/y >coordinates relative to start and end point (I'm currently working on a > >formula - should be no problem) > > >I think that this way tweaks to curves could be much more stable and >the >needed input values could be more easily guessed, so you wouldn't need >that much trial & error... > >Is there a way to set the anchor points for curves? > >I thought of something like: (reference point; offset) >Maybe it could be useful for the middle points to switch between >"offset >relative to straight line" and standard x/y coordinates relative to >start/end point > > >\override Slur.control-points = #'(NoteHead 0 . 0)(StartPoint rotated 0 > >. 0)(EndPoint standard 0 . 0)(Stem 0 . 0)) > > >Probably I need some help with the scheme code for this function.... > >What do you think of this idea? >
Take a look at shapeII at https://github.com/openlilylib/openlilylib/tree/master/notation-snippets/shaping-bezier-curves Provides a number of additional ways to tweak curves. Does this help? Urs >Yours, >musicus > >------------------------------------------------------------------------ > >_______________________________________________ >lilypond-user mailing list >lilypond-user@gnu.org >https://lists.gnu.org/mailman/listinfo/lilypond-user _______________________________________________ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user