Re: [frogs] Re: Numeric note heads for singers

[ Thread Index | Date Index | More lilynet.net/frogs Archives ]




On 1/7/10 1:53 PM, "Neil Puttock" <n.puttock@xxxxxxxxx> wrote:

> 2010/1/7 Carl Sorensen <c_sorensen@xxxxxxx>:
>> On 1/6/10 12:30 PM, "pounderd@xxxxxxxxxxx" <pounderd@xxxxxxxxxxx> wrote:
>>>> 
>>> UNIX-mode on:
>>> 
>>> After unsuccessfully trying to find a way to access the tonic
>>> information from the stencil callback, I've finally realised that the
>>> contexts don't exist when the stencils are called. It therefore seems
>>> that I'm going to need to modify the engraver to set the scale-degree
>>> as an internal grob property.
>>> 
>>> To do this I'm going to have to set-up a dual boot, re-read all the
>>> git stuff and practice building and testing, so please shriek if I'm
>>> going down the wrong route :)
>> 
>> Actually, I think you've got it exactly nailed.  I didn't foresee this
>> difficulty when I said it would be an easy job...
> 
> I think this approach is wrong: since you need to specify the start
> pitch (i.e., the note which will be labelled `1'), which could be in
> any octave, knowing the tonic (from which a scale degree would be
> computed) isn't very useful.

Neil, your understanding of the code is certainly greater than mine, so I
don't want to disagree with you.  But let me explain my thought a little bit
more, so you can help me see why my approach is wrong.

In lily/note-heads-engraver.cc, line 93, the engraver does

note->set_property ("staff-position", scm_from_int (pos));

Then, at line 106, the scale degree that is used to look up
shape notes is calculated as delta.

My thought was that we could then do

note->set_property ("scale-degree"", scm_from_int (delta));

Then, when it's time to do the easyShapeNoteHead, we can get the scale
degree of the note-head by checking its scale-degree property.

Why is this a bad approach?

Thanks,

Carl


---
----
Join the Frogs!


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/