Re: function to recognise voice crossings?

2022-09-17 Thread Lukas-Fabian Moser

Hi Eef,

Am 17.09.22 um 10:52 schrieb Eef Weenink:
PS; I you might change the engraver, consider to NOT colour equal 
notes. (or make it an option). Equal notes do not harm the harmonic 
line. (for seeing where the lowest notes are, it might be set to #t). 


Yes, I suspected that this might not be fitting for your need.

In my case, I wanted to mark the notes in a canon where the current line 
takes over the bass function: This is an interesting question in the 
construction of a canon, where the composer might add the bass notes 
"all at the same time" (usually at the end, creating additional 
voice-leading constraints for the voices entering before that) like in 
Mozart's /Bona Nox/:


or the bass might be constituted in different parts of the pieces by 
different bits in the melody like in Mozart's /Gehn wir im Prater, gehn 
wir in'd Hetz/:


Anyway: See attached. The engraver (now called in LilyPond syntax with 
\) now takes a mandatory argument indicating if only strict lowest notes 
should be coloured (#t) or not (#f). (I think the meaning of #t and #f 
is switched with respect to what you proposed.)


Lukas
\version "2.23"

%  Bass_highlighter_engraver =

#(set-object-property! 'bass-notehead-callback 'backend-type? procedure?)
#(set-object-property! 'bass-notehead-callback 'backend-doc "Function to be called on grob if it is a bass notehead")

#(define (is-lowest? el lst less? strict)
   (every
(lambda (x)
  (or ((if strict eq? equal?) el x)
  (less? el x))) lst))

Bass_highlighter_engraver =
#(define-scheme-function (strict) (boolean?)
   (lambda (context)
   (define (is-over? note moment)
 (not (ly:moment q q q
  }
>>

Re: function to recognise voice crossings?

2022-09-17 Thread Eef Weenink
PS; I you might change the engraver, consider to NOT colour equal notes. (or 
make it an option). Equal notes do not harm the harmonic line. (for seeing 
where the lowest notes are, it might be set to #t).

Eef

Op 17 sep. 2022, om 10:28 heeft Lukas-Fabian Moser 
mailto:l...@gmx.de>> het volgende geschreven:

Ah, thanks, I hadn't considered the possibility of using solo tuning. Sorry for 
the noise.
(I don't think my engraver currently supports setting \transposition to 
accommodate for solo tuning, though.)

Lukas

Eef Weenink mailto:h.e.ween...@de-erve.nl>> schrieb am 
Fr., 16. Sept. 2022, 22:05:
PS: The double bass is in solo tuning (major second above normal) so the score 
for the double bass is written a major second down) so you hear the correct 
pitches.
Purcell (original) is in D minor (1 flat) and the double bass score has 3 flats 
(C minor)

PS2, in fact to do the real check, I have to also transpose the double score 1 
octave down, because the double bass is written 1 octave higher then sounding.

regards, Eef


Op 16 sep. 2022, om 21:47 heeft Lukas-Fabian Moser 
mailto:l...@gmx.de>> het volgende geschreven:


Hi Eef,

Am 16.09.22 um 21:22 schrieb Eef Weenink:
Great, it does exactly what I need, see image. (red noteheads are the lowest in 
score)!
So on this spot I have to lower the bassline in the left hand of piano.


I'm glad it helps!

But there's something strange, as the f-e cadenza in the melody doesn't really 
fit the f major cadenza in the piano.

I looked up Purcell's original (thanks for including the text, otherwise I 
wouldn't have recognized it): The final note of the melody line should coincide 
(up to octave) with the final note of the piano left hand. So it seems 
something's wrong in your score (unless you have some quite unusual clefs, but 
then again, the red markings seem to indicate that melody and piano left hand 
are both written in bass clef).

Could you maybe post your full score so I could take a look?

Lukas




Re: function to recognise voice crossings?

2022-09-17 Thread Eef Weenink
Not needed in the engraver. I have a alltoolsineedfordb.ly with functions for 
that, so just by adding/removing a % I can use them.
For finding good harmonic solutions it is most easy to see both lines in the 
same key/clef.


Met vriendelijke groet, Eef

H.E. Weenink MBA

Op 17 sep. 2022 om 10:28 heeft Lukas-Fabian Moser  het volgende 
geschreven:


Ah, thanks, I hadn't considered the possibility of using solo tuning. Sorry for 
the noise.
(I don't think my engraver currently supports setting \transposition to 
accommodate for solo tuning, though.)

Lukas

Eef Weenink mailto:h.e.ween...@de-erve.nl>> schrieb am 
Fr., 16. Sept. 2022, 22:05:
PS: The double bass is in solo tuning (major second above normal) so the score 
for the double bass is written a major second down) so you hear the correct 
pitches.
Purcell (original) is in D minor (1 flat) and the double bass score has 3 flats 
(C minor)

PS2, in fact to do the real check, I have to also transpose the double score 1 
octave down, because the double bass is written 1 octave higher then sounding.

regards, Eef


Op 16 sep. 2022, om 21:47 heeft Lukas-Fabian Moser 
mailto:l...@gmx.de>> het volgende geschreven:


Hi Eef,

Am 16.09.22 um 21:22 schrieb Eef Weenink:
Great, it does exactly what I need, see image. (red noteheads are the lowest in 
score)!
So on this spot I have to lower the bassline in the left hand of piano.


I'm glad it helps!

But there's something strange, as the f-e cadenza in the melody doesn't really 
fit the f major cadenza in the piano.

I looked up Purcell's original (thanks for including the text, otherwise I 
wouldn't have recognized it): The final note of the melody line should coincide 
(up to octave) with the final note of the piano left hand. So it seems 
something's wrong in your score (unless you have some quite unusual clefs, but 
then again, the red markings seem to indicate that melody and piano left hand 
are both written in bass clef).

Could you maybe post your full score so I could take a look?

Lukas



Re: function to recognise voice crossings?

2022-09-17 Thread Lukas-Fabian Moser
Ah, thanks, I hadn't considered the possibility of using solo tuning. 
Sorry for the noise.
(I don't think my engraver currently supports setting \transposition to 
accommodate for solo tuning, though.)


Lukas

Eef Weenink  schrieb am Fr., 16. Sept. 2022, 22:05:

   PS: The double bass is in solo tuning (major second above normal) so
   the score for the double bass is written a major second down) so you
   hear the correct pitches.
   Purcell (original) is in D minor (1 flat) and the double bass score
   has 3 flats (C minor)

   PS2, in fact to do the real check, I have to also transpose the
   double score 1 octave down, because the double bass is written 1
   octave higher then sounding.

   regards, Eef



Op 16 sep. 2022, om 21:47 heeft Lukas-Fabian Moser 
het volgende geschreven:

Hi Eef,

Am 16.09.22 um 21:22 schrieb Eef Weenink:

Great, it does exactly what I need, see image. (red noteheads are
the lowest in score)!
So on this spot I have to lower the bassline in the left hand of
piano.



I'm glad it helps!

But there's something strange, as the f-e cadenza in the melody
doesn't really fit the f major cadenza in the piano.

I looked up Purcell's original (thanks for including the text,
otherwise I wouldn't have recognized it): The final note of the
melody line should coincide (up to octave) with the final note of
the piano left hand. So it seems something's wrong in your score
(unless you have some quite unusual clefs, but then again, the red
markings seem to indicate that melody and piano left hand are both
written in bass clef).

Could you maybe post your full score so I could take a look?

Lukas



Re: function to recognise voice crossings?

2022-09-16 Thread h.e.weenink
PS

To be precise. Bring it back to D minor and then octave down. 😉

Van: Eef Weenink 
Verzonden: vrijdag 16 september 2022 22:05
Aan: Lukas-Fabian Moser 
CC: Lilypond-User Mailing List 
Onderwerp: Re: function to recognise voice crossings?

PS: The double bass is in solo tuning (major second above normal) so the score 
for the double bass is written a major second down) so you hear the correct 
pitches.
Purcell (original) is in D minor (1 flat) and the double bass score has 3 flats 
(C minor)

PS2, in fact to do the real check, I have to also transpose the double score 1 
octave down, because the double bass is written 1 octave higher then sounding.

regards, Eef


Op 16 sep. 2022, om 21:47 heeft Lukas-Fabian Moser 
mailto:l...@gmx.de>> het volgende geschreven:


Hi Eef,

Am 16.09.22 um 21:22 schrieb Eef Weenink:
Great, it does exactly what I need, see image. (red noteheads are the lowest in 
score)!
So on this spot I have to lower the bassline in the left hand of piano.


I'm glad it helps!

But there's something strange, as the f-e cadenza in the melody doesn't really 
fit the f major cadenza in the piano.

I looked up Purcell's original (thanks for including the text, otherwise I 
wouldn't have recognized it): The final note of the melody line should coincide 
(up to octave) with the final note of the piano left hand. So it seems 
something's wrong in your score (unless you have some quite unusual clefs, but 
then again, the red markings seem to indicate that melody and piano left hand 
are both written in bass clef).

Could you maybe post your full score so I could take a look?

Lukas



Re: function to recognise voice crossings?

2022-09-16 Thread Eef Weenink
PS: The double bass is in solo tuning (major second above normal) so the score 
for the double bass is written a major second down) so you hear the correct 
pitches.
Purcell (original) is in D minor (1 flat) and the double bass score has 3 flats 
(C minor)

PS2, in fact to do the real check, I have to also transpose the double score 1 
octave down, because the double bass is written 1 octave higher then sounding.

regards, Eef


Op 16 sep. 2022, om 21:47 heeft Lukas-Fabian Moser 
mailto:l...@gmx.de>> het volgende geschreven:


Hi Eef,

Am 16.09.22 um 21:22 schrieb Eef Weenink:
Great, it does exactly what I need, see image. (red noteheads are the lowest in 
score)!
So on this spot I have to lower the bassline in the left hand of piano.


I'm glad it helps!

But there's something strange, as the f-e cadenza in the melody doesn't really 
fit the f major cadenza in the piano.

I looked up Purcell's original (thanks for including the text, otherwise I 
wouldn't have recognized it): The final note of the melody line should coincide 
(up to octave) with the final note of the piano left hand. So it seems 
something's wrong in your score (unless you have some quite unusual clefs, but 
then again, the red markings seem to indicate that melody and piano left hand 
are both written in bass clef).

Could you maybe post your full score so I could take a look?

Lukas



Re: function to recognise voice crossings?

2022-09-16 Thread Lukas-Fabian Moser

Hi Eef,

Am 16.09.22 um 21:22 schrieb Eef Weenink:
Great, it does exactly what I need, see image. (red noteheads are the 
lowest in score)!

So on this spot I have to lower the bassline in the left hand of piano.


I'm glad it helps!

But there's something strange, as the f-e cadenza in the melody doesn't 
really fit the f major cadenza in the piano.


I looked up Purcell's original (thanks for including the text, otherwise 
I wouldn't have recognized it): The final note of the melody line should 
coincide (up to octave) with the final note of the piano left hand. So 
it seems something's wrong in your score (unless you have some quite 
unusual clefs, but then again, the red markings seem to indicate that 
melody and piano left hand are both written in bass clef).


Could you maybe post your full score so I could take a look?

Lukas


Re: function to recognise voice crossings?

2022-09-16 Thread Eef Weenink
Great, it does exactly what I need, see image. (red noteheads are the lowest in 
score)!
So on this spot I have to lower the bassline in the left hand of piano.
[cid:29D04ECB-8577-4403-99DE-D62C6AC64E40]


Op 16 sep. 2022, om 18:55 heeft Lukas-Fabian Moser 
mailto:l...@gmx.de>> het volgende geschreven:

Hi Eef,

Am 16.09.22 um 13:53 schrieb Eef Weenink:
I write mostly arrangements where I bring a melody voice down to the double 
bass (my instrument :-))

Double bass is written an octave higher then sounding, so a lot of times, the 
score lookes OK, but in fact there are voice crossings between lefthand of 
piano and the double bass (what gives unwanted/unpleasant voice crossings.

To check this, I transpose the double bass voice down an octave and manually 
check the boths voices.

Wonder if there is a function in lilypond to do this fastly. Like the coloured 
noteheads when checking a voice against the ambitus of an instrument.

This reminds me of a function I wrote last year to automatically colourise the 
lowest sounding pitch in a score. (In my case, this was for harmonic analysis 
of canons.) See attached.

Maybe this could be used or at least adapted?

Lukashttp://lowest-notes.ly>>



Re: function to recognise voice crossings?

2022-09-16 Thread Eef Weenink
I will check this. Thanks


Met vriendelijke groet, Eef

H.E. Weenink MBA

Op 16 sep. 2022 om 18:56 heeft Lukas-Fabian Moser  het volgende 
geschreven:

Hi Eef,

Am 16.09.22 um 13:53 schrieb Eef Weenink:
I write mostly arrangements where I bring a melody voice down to the double 
bass (my instrument :-))

Double bass is written an octave higher then sounding, so a lot of times, the 
score lookes OK, but in fact there are voice crossings between lefthand of 
piano and the double bass (what gives unwanted/unpleasant voice crossings.

To check this, I transpose the double bass voice down an octave and manually 
check the boths voices.

Wonder if there is a function in lilypond to do this fastly. Like the coloured 
noteheads when checking a voice against the ambitus of an instrument.

This reminds me of a function I wrote last year to automatically colourise the 
lowest sounding pitch in a score. (In my case, this was for harmonic analysis 
of canons.) See attached.

Maybe this could be used or at least adapted?

Lukas


lowest-notes.ly
Description: lowest-notes.ly


Re: function to recognise voice crossings?

2022-09-16 Thread Eef Weenink
This is not the question. It is about voice crossing bassline (left hand piano) 
and melodyline (double bass). That gives inversions, mostly not wanted. 
So these need to be identified. 


Met vriendelijke groet, Eef

H.E. Weenink MBA

> Op 16 sep. 2022 om 18:25 heeft Wols Lists  het 
> volgende geschreven:
> 
> Or just use the "correct" clef :-)
> 
> The trombone is written a ninth higher than sounding, so I transpose it down 
> a second (to deal with the B-flat-ness) and then use the treble_8 clef to 
> print it correctly.
> 
> That way, all your notes are correct, both as regards lily's internal pitch, 
> and as they appear on the page.



Re: function to recognise voice crossings?

2022-09-16 Thread Lukas-Fabian Moser

Hi Eef,

Am 16.09.22 um 13:53 schrieb Eef Weenink:

I write mostly arrangements where I bring a melody voice down to the double 
bass (my instrument :-))

Double bass is written an octave higher then sounding, so a lot of times, the 
score lookes OK, but in fact there are voice crossings between lefthand of 
piano and the double bass (what gives unwanted/unpleasant voice crossings.

To check this, I transpose the double bass voice down an octave and manually 
check the boths voices.

Wonder if there is a function in lilypond to do this fastly. Like the coloured 
noteheads when checking a voice against the ambitus of an instrument.


This reminds me of a function I wrote last year to automatically 
colourise the lowest sounding pitch in a score. (In my case, this was 
for harmonic analysis of canons.) See attached.


Maybe this could be used or at least adapted?

Lukas\version "2.23"

%  Bass_highlighter_engraver =

#(set-object-property! 'bass-notehead-callback 'backend-type? procedure?)
#(set-object-property! 'bass-notehead-callback 'backend-doc "Function to be called on grob if it is a bass notehead")

#(define (is-lower-bound? el lst less?)
   ; returns #t if no element of lst is less? than el.
   (if (pair? lst)
   (if (less? (car lst) el)
   #f
   (is-lower-bound? el (cdr lst) less?))
   #t))

Bass_highlighter_engraver =
#(lambda (context)
   (define (is-over? note moment)
 (not (ly:moment q q q
  }
>>

Re: function to recognise voice crossings?

2022-09-16 Thread Wols Lists

On 16/09/2022 12:53, Eef Weenink wrote:

To check this, I transpose the double bass voice down an octave and manually 
check the boths voices.

Wonder if there is a function in lilypond to do this fastly. Like the coloured 
noteheads when checking a voice against the ambitus of an instrument.


Or just use the "correct" clef :-)

The trombone is written a ninth higher than sounding, so I transpose it 
down a second (to deal with the B-flat-ness) and then use the treble_8 
clef to print it correctly.


That way, all your notes are correct, both as regards lily's internal 
pitch, and as they appear on the page.


Cheers,
Wol



function to recognise voice crossings?

2022-09-16 Thread Eef Weenink
Hello all, 

I write mostly arrangements where I bring a melody voice down to the double 
bass (my instrument :-)) 

Double bass is written an octave higher then sounding, so a lot of times, the 
score lookes OK, but in fact there are voice crossings between lefthand of 
piano and the double bass (what gives unwanted/unpleasant voice crossings. 

To check this, I transpose the double bass voice down an octave and manually 
check the boths voices. 

Wonder if there is a function in lilypond to do this fastly. Like the coloured 
noteheads when checking a voice against the ambitus of an instrument. 

Regards, Eef