Fix issue 4355 -- broken beam subdivision
When beams are subdivided, the number of beams joining the subdivisions
should match the length of the subdivision. Previously, the subdivisions
were joined by a single beam.
Thank you for picking this up. It is certainly an improvement already. However: In an ...
8 years, 11 months ago
(2015-04-25 08:20:52 UTC)
#2
Thank you for picking this up. It is certainly an improvement already.
However: In an example where 8 32th notes are subdivided by 16th notes ony the
first and third subdivision should have two beams, the second one only one beam.
Put differently: when there is following a total of an eighth note's worth there
should be only one beam, even when that total is itself subdivided into two
sixteenth notes. (Presumably that logic should be propagated to the situation of
(nested shorter notes): when 16 64th notes are subdivided by 32ths the divisions
should should have the following number of beams: 3-2-3-1-3-2-3.
On 2015/04/25 08:20:52, uliska wrote: > Thank you for picking this up. It is certainly ...
8 years, 11 months ago
(2015-04-25 08:26:27 UTC)
#3
On 2015/04/25 08:20:52, uliska wrote:
> Thank you for picking this up. It is certainly an improvement already.
>
> However: In an example where 8 32th notes are subdivided by 16th notes ony the
> first and third subdivision should have two beams, the second one only one
beam.
>
> Put differently: when there is following a total of an eighth note's worth
there
> should be only one beam, even when that total is itself subdivided into two
> sixteenth notes. (Presumably that logic should be propagated to the situation
of
> (nested shorter notes): when 16 64th notes are subdivided by 32ths the
divisions
> should should have the following number of beams: 3-2-3-1-3-2-3.
I would add the following to the regression test:
\set baseMoment = #(ly:make-moment 1 32)
c''64[ c'' c'' c'' c'' c'' c'' c'' c'' c'' c'' c'' c'' c'' c'' c'']
and this should have the beaming pattern given in my previous comment
Ok, so let me see if I understand what you are saying. When we choose ...
8 years, 11 months ago
(2015-04-25 11:33:01 UTC)
#4
Ok, so let me see if I understand what you are saying.
When we choose to subdivide beams with a given baseMoment, there should be a
subdivision at baseMoment and at every even interval larger than that.
So if we have a baseMoment of 1/32, we should subdivide at 1/32, 1/16, and 1/8.
If we have a baseMoment of 1/16, we should subdivide at 1/16 and 1/8.
If we have a baseMoment of 1/8, we should subdivide at 1/8.
And presumably if we have a baseMoment of 1/128, we should subdivide at 1/128,
1/64, 1/32, 1/16, and 1/8.
Is this correct?
2015-04-25 10:20 GMT+02:00 <lilyliska@googlemail.com>: > Thank you for picking this up. It is certainly an ...
8 years, 11 months ago
(2015-04-25 11:54:01 UTC)
#5
2015-04-25 10:20 GMT+02:00 <lilyliska@googlemail.com>:
> Thank you for picking this up. It is certainly an improvement already.
>
> However: In an example where 8 32th notes are subdivided by 16th notes
> ony the first and third subdivision should have two beams, the second
> one only one beam.
>
> Put differently: when there is following a total of an eighth note's
> worth there should be only one beam, even when that total is itself
> subdivided into two sixteenth notes. (Presumably that logic should be
> propagated to the situation of (nested shorter notes): when 16 64th
> notes are subdivided by 32ths the divisions should should have the
> following number of beams: 3-2-3-1-3-2-3.
could you formulate this more generally?
e.g. what to do with 12 32th notes?
p
On 2015/04/25 11:54:01, benko.pal wrote: > 2015-04-25 10:20 GMT+02:00 <mailto:lilyliska@googlemail.com>: > > Thank you for ...
8 years, 11 months ago
(2015-04-25 22:58:56 UTC)
#7
On 2015/04/25 11:54:01, benko.pal wrote:
> 2015-04-25 10:20 GMT+02:00 <mailto:lilyliska@googlemail.com>:
> > Thank you for picking this up. It is certainly an improvement already.
> >
> > However: In an example where 8 32th notes are subdivided by 16th notes
> > ony the first and third subdivision should have two beams, the second
> > one only one beam.
> >
> > Put differently: when there is following a total of an eighth note's
> > worth there should be only one beam, even when that total is itself
> > subdivided into two sixteenth notes. (Presumably that logic should be
> > propagated to the situation of (nested shorter notes): when 16 64th
> > notes are subdivided by 32ths the divisions should should have the
> > following number of beams: 3-2-3-1-3-2-3.
>
> could you formulate this more generally?
> e.g. what to do with 12 32th notes?
>
> p
If we have a baseMoment of 1/16, the 12 32nd notes will occur in 6 pairs with 3
beams.
The 1st and 2nd pairs will be joined with a double beam, as will the 3rd and
4th, and the 5th and 6th.
The beam between the 2nd and 3rd pair will be a single beam, as will the beam
between the 4th and 5th.
On 2015/04/25 22:58:56, Carl wrote: > On 2015/04/25 11:54:01, benko.pal wrote: > > 2015-04-25 10:20 ...
8 years, 11 months ago
(2015-04-26 00:01:14 UTC)
#8
On 2015/04/25 22:58:56, Carl wrote:
> On 2015/04/25 11:54:01, benko.pal wrote:
> > 2015-04-25 10:20 GMT+02:00 <mailto:lilyliska@googlemail.com>:
> > > Thank you for picking this up. It is certainly an improvement already.
> > >
> > > However: In an example where 8 32th notes are subdivided by 16th notes
> > > ony the first and third subdivision should have two beams, the second
> > > one only one beam.
> > >
> > > Put differently: when there is following a total of an eighth note's
> > > worth there should be only one beam, even when that total is itself
> > > subdivided into two sixteenth notes. (Presumably that logic should be
> > > propagated to the situation of (nested shorter notes): when 16 64th
> > > notes are subdivided by 32ths the divisions should should have the
> > > following number of beams: 3-2-3-1-3-2-3.
> >
> > could you formulate this more generally?
> > e.g. what to do with 12 32th notes?
> >
> > p
>
> If we have a baseMoment of 1/16, the 12 32nd notes will occur in 6 pairs with
3
> beams.
>
> The 1st and 2nd pairs will be joined with a double beam, as will the 3rd and
> 4th, and the 5th and 6th.
>
> The beam between the 2nd and 3rd pair will be a single beam, as will the beam
> between the 4th and 5th.
LGTM.
I don't understand the code, but the regression tests (and my own files) produce
the correct result now.
I have now checked the code for my interface idea, and it seems to work. ...
8 years, 11 months ago
(2015-04-26 00:22:01 UTC)
#9
I have now checked the code for my interface idea, and it seems to work. In
short, I did the following:
- assign the subdivideBeams context property to base_moment
- set subdivide_beams_ to true or false, depending on the value of base_moment_
- change to predicate of subdivideBeams to ly:moment?
As a result you can write
\set subdivideBeams = #(ly:make-moment 1 16)
to activate beam subdivision, and
\set subdivideBeams = ##f to deactivate it
In effect this would make the baseMoment property obsolete and simplify things.
If baseMoment really is only there for beam subdivision then I think the name
isn't the best after all because it sounds like it would have some deeper impact
("baseMoment" for what?). And it would reduce the work by one step as it
replaces the two-step:
\set subdivideBeams = ##t
\set baseMoment = #(ly:make-moment 1 16)
In order to implement this properly one would additionally have to
- remove the context property definition of baseMoment
- create a convert-ly rule
- update the documentation
I would like to see this change (and could give it a try), but it does not
necessarily have to be in the current patch.
baseMoment does have another use. It is used to define the major beaming groups for ...
8 years, 11 months ago
(2015-04-26 02:35:34 UTC)
#10
baseMoment does have another use. It is used to define the major beaming groups
for automatic beaming.
So if you have a 5/8 time signature, and you want to beam it 3+2, you would do
the following:
\set baseMoment = #(ly:make-moment 1 8)
\set beatStructure = '(3 2)
If you want to subdivide the beams at 1/16 instead of at 1/8, you would do
\set baseMoment = #(ly:make-moment 1 16)
\set beatStructure = '(6 4)
And this use of baseMoment is important for subdivision; subdivision is only
possible at units of baseMoment.
Thanks,
Carl
On 2015/04/26 02:35:34, Carl wrote: > baseMoment does have another use. It is used to ...
8 years, 11 months ago
(2015-04-26 13:49:33 UTC)
#12
On 2015/04/26 02:35:34, Carl wrote:
> baseMoment does have another use. It is used to define the major beaming
groups
> for automatic beaming.
>
> ...
>
> And this use of baseMoment is important for subdivision; subdivision is only
> possible at units of baseMoment.
>
> Thanks,
>
> Carl
OK, so I "withdraw" my suggestions. Was a nice experience to make changes to a
C++ file that had working and visible effects, though ;-)
So, I repeat: LGTM
This is a test upload to see if git-cl works with testlily on sourceforge. Please ...
8 years, 10 months ago
(2015-05-23 22:38:21 UTC)
#15
This is a test upload to see if git-cl works with testlily on sourceforge.
Please do not review this patch; it has already been pushed, but the SourceForge
issue tracker doesn't know it.
Issue 226700043: Fix issue 4355 -- broken beam subdivision
Created 8 years, 11 months ago by Carl
Modified 8 years, 10 months ago
Reviewers: lemzwerg, uliska, benko.pal, Trevor Daniels
Base URL:
Comments: 0