Bass and chords

classic Classic list List threaded Threaded
14 messages Options
Reply | Threaded
Open this post in threaded view
|

Bass and chords

Fred
Hi,
I'm using Lilypond to write traditional folk music for diatonic accordion.
On that kind of instrument you have the melody (done with the right hand) and the bass and chords done by the left hand.
Typically the melody is written as a normal score and the left hand (bass and chord) is written like this: uppercase letter for chords and lower case for chords.
Let's say you want a C bass, then a C major chord, then a G bass and then a G major chord, under the score you find:
C c G g
More "complex" things such as mixed bass and chords have also their convention: chord of F bass of D is written like: f/D

I wonder what is the best way to write it with Lilypond?

Adding the chords with \chords is no problem but then I can't indicate when is it bass only and when is it chord.
Adding this notation as pure text is possible but I would find very pity to not get the midi file and to make transpose impossible.

Finally, if it would be possible to note "no chord" as a normal rest of the correct duration instead of N.C. it would be great.

Thanks,

Fred

_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

David Kastrup
Frédéric Fanchamps <[hidden email]> writes:

> Hi,
> I'm using Lilypond to write traditional folk music for diatonic
> accordion.
> On that kind of instrument you have the melody (done with the right
> hand) and the bass and chords done by the left hand.
> Typically the melody is written as a normal score and the left hand
> (bass and chord) is written like this: uppercase letter for chords and
> lower case for chords.
> Let's say you want a C bass, then a C major chord, then a G bass and
> then a G major chord, under the score you find:
> C c G g
> More "complex" things such as mixed bass and chords have also their
> convention: chord of F bass of D is written like: f/D

Sounds more like chromatic/unisonoric accordion to me.  For diatonic,
I have rarely seem anything but "Griffschrift".

> I wonder what is the best way to write it with Lilypond?

There is no really convincing builtin support right now.  For neither of
the two, actually.

> Adding the chords with \chords is no problem but then I can't indicate
> when is it bass only and when is it chord.

c:1 is a single note in Midi, but the chord transcription will not
distinguish it from the chord and it will not sound in a lower octave.

There have been discussions on the developer group about mixed
chord/note modes: those would be nice here.  There is also likely a lot
one could do with music functions.

There is an issue
<URL:http://code.google.com/p/lilypond/issues/detail?id=559> which would
correspond with your request (as your request is really coinciding with
chromatic accordion notation rather than the diatonic transcriptions I
know).  But nobody has worked on it so far.

> Adding this notation as pure text is possible but I would find very
> pity to not get the midi file and to make transpose impossible.

Indeed.

> Finally, if it would be possible to note "no chord" as a normal rest
> of the correct duration instead of N.C. it would be great.

Maybe someone else can make a suggestion for this item?

--
David Kastrup


_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

Fred
In reply to this post by Fred
Hi David,

Thanks for your quick answer.

The good news is that it's clear, I understand it and the issue 559 you mentioned would perfectly answer to my needs (much more than that in fact).
The bad news is that it is not implemented yet, so I would probably need to do something (probably simpler) myself if I want it.
Is it possible to participate to the Lilypond project? What are the technical requirements?

A small detail:
>Sounds more like chromatic/unisonoric accordion to me.  For diatonic, I have rarely seem anything but "Griffschrift":
There also beautiful scores for diatonic accordion (or whatever instrument able to play this type of music actually) not only "Griffschrift".

Regards,

Fred

_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

David Kastrup
Frédéric Fanchamps <[hidden email]> writes:

> Hi David,
>
> Thanks for your quick answer.
>
> The good news is that it's clear, I understand it and the issue 559
> you mentioned would perfectly answer to my needs (much more than that
> in fact).
> The bad news is that it is not implemented yet, so I would probably
> need to do something (probably simpler) myself if I want it.
> Is it possible to participate to the Lilypond project? What are the
> technical requirements?

Solid nerves and an open mind.  And then reading the "LilyPond --
Extending" guide.  Most of what you want to do does not require
recompiling LilyPond.  The main programming language with which you
would be working would be Scheme.  Everything else would get much
uglier.

You need to get a good idea of what kind of syntax you want to be
writing, and how this fits with the existing syntax of LilyPond.
Normally, you would not want to mess with syntax, so you need to figure
out what existing syntax/music expression would best express your
intent, and then see how you get from that expression to those you
actually want to see in the score.

--
David Kastrup


_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

Eluze
In reply to this post by David Kastrup
dak wrote
> Finally, if it would be possible to note "no chord" as a normal rest
> of the correct duration instead of N.C. it would be great.

Maybe someone else can make a suggestion for this item?

--
David Kastrup
here is a suggestion:

define a command for the rests like

restFull = {
  \once \set chordChanges = ##f
  \once \set noChordSymbol = \markup { \musicglyph #"rests.1" }
  r1
}
restHalf = {
  \once \set chordChanges = ##f
  \once \set noChordSymbol = \markup { \musicglyph #"rests.2" }
  r2
}

% …

and use them in a score:

harmonies = \chordmode {
  \restHalf \restHalf
  c2:m c:m
  \break
  c1:m c:m d \restFull
}

to be sure use that \once \set … works as expected you should use a recent version of LP.

maybe even that somebody will take care of putting this in a function so that you can use it with normal code!

Eluze
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

Eluze
of course that was rubbish - you have to use rests.0 for a full rest, rests.1 for a half, rests.2  for a quarter  and so on...

Eluze
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

Thomas Morley
In reply to this post by Eluze
2012/11/6 Eluze <[hidden email]>:

> dak wrote
>>> Finally, if it would be possible to note "no chord" as a normal rest
>>> of the correct duration instead of N.C. it would be great.
>>
>> Maybe someone else can make a suggestion for this item?
>>
>> --
>> David Kastrup
>
> here is a suggestion:
>
> define a command for the rests like
>
> restFull = {
>   \once \set chordChanges = ##f
>   \once \set noChordSymbol = \markup { \musicglyph #"rests.1" }
>   r1
> }
> restHalf = {
>   \once \set chordChanges = ##f
>   \once \set noChordSymbol = \markup { \musicglyph #"rests.2" }
>   r2
> }
>
> % …
>
> and use them in a score:
>
> harmonies = \chordmode {
>   \restHalf \restHalf
>   c2:m c:m
>   \break
>   c1:m c:m d \restFull
> }
>
> to be sure use that /\once \set …/ works as expected you should use a recent
> version of LP.
>
> maybe even that somebody will take care of putting this in a function so
> that you can use it with normal code!
>
> Eluze
>
>
>
> --
> View this message in context: http://lilypond.1069038.n5.nabble.com/Bass-and-chords-tp135858p135901.html
> Sent from the User mailing list archive at Nabble.com.
>
> _______________________________________________
> lilypond-user mailing list
> [hidden email]
> https://lists.gnu.org/mailman/listinfo/lilypond-user

More automated:

\version "2.16.0"

chordNamesWithRestsLayout =
\with {
        noChordSymbol = #(make-simple-markup "")
        \consists "Rest_engraver"
        \consists "Multi_measure_rest_engraver"
        \override Rest #'font-size = #-4
        \override MultiMeasureRest #'font-size = #-4
        % No idea, why r1 needs to be special-cased:
        \override Rest #'after-line-breaking =
          #(lambda (grob)
            (let* ((dur-log (ly:grob-property grob 'duration-log))
                   (staff-pos (if (= dur-log 0) 0 2)))
            (ly:grob-set-property! grob 'staff-position staff-pos)))
        \override MultiMeasureRest #'staff-position = #2

}

  <<
  \new ChordNames \with { \chordNamesWithRestsLayout }
  \chordmode { c1 R1 d e }
  \new Staff { c1 R1 d e }
  >>

\score {
  <<
    \new ChordNames
    \chordmode { c1 R1 d e }
    \new Staff { c1 R1 d e }
  >>
  \layout {
          \context {
           \ChordNames
           \chordNamesWithRestsLayout
          }
  }
}


HTH,
  Harm

_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

Eluze

Am 06.11.2012 23:33, schrieb Thomas Morley:
More automated:

\version "2.16.0"

chordNamesWithRestsLayout =
\with {
        noChordSymbol = #(make-simple-markup "")
        \consists "Rest_engraver"
        \consists "Multi_measure_rest_engraver"
        \override Rest #'font-size = #-4
        \override MultiMeasureRest #'font-size = #-4
        % No idea, why r1 needs to be special-cased:
        \override Rest #'after-line-breaking =
          #(lambda (grob)
            (let* ((dur-log (ly:grob-property grob 'duration-log))
                   (staff-pos (if (= dur-log 0) 0 2)))
            (ly:grob-set-property! grob 'staff-position staff-pos)))
        \override MultiMeasureRest #'staff-position = #2

}

  <<
  \new ChordNames \with { \chordNamesWithRestsLayout }
  \chordmode { c1 R1 d e }
  \new Staff { c1 R1 d e }
  >>

\score {
  <<
    \new ChordNames
    \chordmode { c1 R1 d e }
    \new Staff { c1 R1 d e }
  >>
  \layout {
          \context {
          	  \ChordNames
          	  \chordNamesWithRestsLayout
          }
  }
}


thanks Harm - I think that's a superb solution with a fantastical short code - something for the LSR!?

' if you want to replace the "N.C." symbol in a \chordname context by the latent rest you can use … … … …  '

Eluze

_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

Thomas Morley
2012/11/7 Eluze <[hidden email]>:

>
> Am 06.11.2012 23:33, schrieb Thomas Morley:
>
> More automated:
>
> \version "2.16.0"
>
> chordNamesWithRestsLayout =
> \with {
>         noChordSymbol = #(make-simple-markup "")
>         \consists "Rest_engraver"
>         \consists "Multi_measure_rest_engraver"
>         \override Rest #'font-size = #-4
>         \override MultiMeasureRest #'font-size = #-4
>         % No idea, why r1 needs to be special-cased:
>         \override Rest #'after-line-breaking =
>           #(lambda (grob)
>             (let* ((dur-log (ly:grob-property grob 'duration-log))
>                    (staff-pos (if (= dur-log 0) 0 2)))
>             (ly:grob-set-property! grob 'staff-position staff-pos)))
>         \override MultiMeasureRest #'staff-position = #2
>
> }
>
>   <<
>   \new ChordNames \with { \chordNamesWithRestsLayout }
>   \chordmode { c1 R1 d e }
>   \new Staff { c1 R1 d e }
>   >>
>
> \score {
>   <<
>     \new ChordNames
>     \chordmode { c1 R1 d e }
>     \new Staff { c1 R1 d e }
>   >>
>   \layout {
>           \context {
>            \ChordNames
>            \chordNamesWithRestsLayout
>           }
>   }
> }
>
>
> thanks Harm - I think that's a superb solution with a fantastical short code
> - something for the LSR!?
>
> ' if you want to replace the "N.C." symbol in a \chordname context by the
> latent rest you can use … … … …  '
>
> Eluze
>

Will do, if noone comes up with a better solution or finds a drawback.

Regards,
  Harm

_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

David Kastrup
Thomas Morley <[hidden email]> writes:

> Will do, if noone comes up with a better solution or finds a drawback.

We have markup commands \note and \note-by-number.  It seems to me that
it would likely be most straightforward to provide the same for \rest
and possibly \rest-by-number and use that as part of the solution.

--
David Kastrup


_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

Thomas Morley
2012/11/7 David Kastrup <[hidden email]>:
> Thomas Morley <[hidden email]> writes:
>
>> Will do, if noone comes up with a better solution or finds a drawback.
>
> We have markup commands \note and \note-by-number.  It seems to me that
> it would likely be most straightforward to provide the same for \rest
> and possibly \rest-by-number and use that as part of the solution.

Seems you don't like the context-modifications. :)

What should \rest-by-number do, what \musicglyph can't?
Proper output of R1*x?
More?

And how to use it?
Perhaps:
\once \set ChordNames.noChordSymbol = \markup \rest-by-number
<reading/processing duration and style>
?

-Harm

_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

David Kastrup
Thomas Morley <[hidden email]> writes:

> 2012/11/7 David Kastrup <[hidden email]>:
>> Thomas Morley <[hidden email]> writes:
>>
>>> Will do, if noone comes up with a better solution or finds a drawback.
>>
>> We have markup commands \note and \note-by-number.  It seems to me that
>> it would likely be most straightforward to provide the same for \rest
>> and possibly \rest-by-number and use that as part of the solution.
>
> Seems you don't like the context-modifications. :)
>
> What should \rest-by-number do, what \musicglyph can't?

Spare the user from having to know what glyphs and fonts to use?  With
luck, this is just a matter of copy and paste from the
\note/\note-by-number code with changes in the selected muic glyphs.

--
David Kastrup

_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

Thomas Morley
2012/11/12 David Kastrup <[hidden email]>:

> Thomas Morley <[hidden email]> writes:
>
>> 2012/11/7 David Kastrup <[hidden email]>:
>>> Thomas Morley <[hidden email]> writes:
>>>
>>>> Will do, if noone comes up with a better solution or finds a drawback.
>>>
>>> We have markup commands \note and \note-by-number.  It seems to me that
>>> it would likely be most straightforward to provide the same for \rest
>>> and possibly \rest-by-number and use that as part of the solution.
>>
>> Seems you don't like the context-modifications. :)
>>
>> What should \rest-by-number do, what \musicglyph can't?
>
> Spare the user from having to know what glyphs and fonts to use?  With
> luck, this is just a matter of copy and paste from the
> \note/\note-by-number code with changes in the selected muic glyphs.
>
> --
> David Kastrup

No luck.
I tried this already.
Will take another road the upcomming days.

-Harm

_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user
Reply | Threaded
Open this post in threaded view
|

Re: Bass and chords

David Kastrup
Thomas Morley <[hidden email]> writes:

> 2012/11/12 David Kastrup <[hidden email]>:
>> Thomas Morley <[hidden email]> writes:
>>
>>> 2012/11/7 David Kastrup <[hidden email]>:
>>>> Thomas Morley <[hidden email]> writes:
>>>>
>>>>> Will do, if noone comes up with a better solution or finds a drawback.
>>>>
>>>> We have markup commands \note and \note-by-number.  It seems to me that
>>>> it would likely be most straightforward to provide the same for \rest
>>>> and possibly \rest-by-number and use that as part of the solution.
>>>
>>> Seems you don't like the context-modifications. :)
>>>
>>> What should \rest-by-number do, what \musicglyph can't?
>>
>> Spare the user from having to know what glyphs and fonts to use?  With
>> luck, this is just a matter of copy and paste from the
>> \note/\note-by-number code with changes in the selected muic glyphs.
>
> No luck.
> I tried this already.

Ah, pity.  If this task is harder than it seems, it would probably be
even more helpful to provide it as a ready-made service.

One obvious consideration is that for use in markup, you would need the
glyphs intended for outside-staff use (those with their own ledger
lines).

--
David Kastrup

_______________________________________________
lilypond-user mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/lilypond-user