Closed craigsapp closed 7 years ago
Putting both values in one single <artic>
element should work:
<staff xml:id="staff-0000000976822979" n="1">
<layer xml:id="layer-L1F1N1" n="1">
<note xml:id="note-L3F1S1-below" dur="4" oct="4" pname="e" accid.ges="n">
<artic xml:id="artic-0000000395580946" artic="stacc ten" place="below" />
</note>
<note xml:id="note-L4F1S1-above" dur="4" oct="5" pname="f" accid.ges="n">
<artic xml:id="artic-0000000148826777" artic="ten stacc" place="above" />
</note>
</layer>
</staff>
I could do the merging in the converter, but would be useful to make the merge in verovio after it makes a decision as to where the unplaced articulation should go (above or below). If an unplaced articulation occurs on the same side of a note as a placed articulation, then the two articulations should not overstrike.
Otherwise, the case where an unplaced articulation occurs on the same note as a placed articulation should be flagged with a warning in the schematron rules.
When the placed articulation is on the opposite side of the automatically placed articulation, the expected notation is rendered:
<?xml version="1.0" encoding="UTF-8"?>
<?xml-model href="http://music-encoding.org/schema/4.0.0/mei-all.rng" type="application/xml" schematypens="http://relaxng.org/ns/structure/1.0"?>
<?xml-model href="http://music-encoding.org/schema/4.0.0/mei-all.rng" type="application/xml" schematypens="http://purl.oclc.org/dsdl/schematron"?>
<mei xmlns="http://www.music-encoding.org/ns/mei" meiversion="4.0.0">
<meiHead>
<fileDesc>
<titleStmt>
<title />
</titleStmt>
<pubStmt />
</fileDesc>
<workDesc>
<work>
<titleStmt>
<title />
</titleStmt>
</work>
</workDesc>
</meiHead>
<music>
<body>
<mdiv>
<score>
<scoreDef xml:id="scoredef-0000001270737384">
<staffGrp xml:id="staffgrp-0000000993412322">
<staffDef xml:id="staffdef-0000001743024076" clef.shape="G" clef.line="2" meter.count="2" meter.unit="4" n="1" lines="5" />
</staffGrp>
</scoreDef>
<section xml:id="section-0000001722696968">
<measure xml:id="measure-L1" right="end" n="0">
<staff xml:id="staff-0000000016102605" n="1">
<layer xml:id="layer-L1F1N1" n="1">
<note xml:id="note-L3F1" dur="4" oct="4" pname="e" accid.ges="n">
<artic xml:id="artic-L3F1a" artic="stacc" place="above" />
<artic xml:id="artic-L3F1b" artic="ten" />
</note>
</layer>
</staff>
</measure>
</section>
</score>
</mdiv>
</body>
</music>
</mei>
If the placed articulation occurs on the same side as the automatically placed articulation, the two articulations are overstriking, which is not expected:
<?xml version="1.0" encoding="UTF-8"?>
<?xml-model href="http://music-encoding.org/schema/4.0.0/mei-all.rng" type="application/xml" schematypens="http://relaxng.org/ns/structure/1.0"?>
<?xml-model href="http://music-encoding.org/schema/4.0.0/mei-all.rng" type="application/xml" schematypens="http://purl.oclc.org/dsdl/schematron"?>
<mei xmlns="http://www.music-encoding.org/ns/mei" meiversion="4.0.0">
<meiHead>
<fileDesc>
<titleStmt>
<title />
</titleStmt>
<pubStmt />
</fileDesc>
<workDesc>
<work>
<titleStmt>
<title />
</titleStmt>
</work>
</workDesc>
</meiHead>
<music>
<body>
<mdiv>
<score>
<scoreDef xml:id="scoredef-0000001270737384">
<staffGrp xml:id="staffgrp-0000000993412322">
<staffDef xml:id="staffdef-0000001743024076" clef.shape="G" clef.line="2" meter.count="2" meter.unit="4" n="1" lines="5" />
</staffGrp>
</scoreDef>
<section xml:id="section-0000001722696968">
<measure xml:id="measure-L1" right="end" n="0">
<staff xml:id="staff-0000000016102605" n="1">
<layer xml:id="layer-L1F1N1" n="1">
<note xml:id="note-L3F1" dur="4" oct="4" pname="e" accid.ges="n">
<artic xml:id="artic-L3F1a" artic="stacc" place="below" />
<artic xml:id="artic-L3F1b" artic="ten" />
</note>
</layer>
</staff>
</measure>
</section>
</score>
</mdiv>
</body>
</music>
</mei>
Verovio can't merge two artic
elements. You would loose one ID!
I would prefer you to do it in the converter ;-) because Verovio can render all the situations desired. This is mostly about supporting another way of encoding the same thing. Should this be really desired I would be tempted to remove the current support we have of multiple values in @artic
and require each of them to be put in a separated <artic>
element.
Verovio can't merge two artic elements. You would loose one ID!
I don't mean merge in the MEI structure, but merge in the sense that both need to be displayed graphically and independently, and their placement with respect to each other must be considered if they end up both on the same side of the note (rather than overstriking).
I would prefer you to do it in the converter ;-) because Verovio can render all the situations desired. This is mostly about supporting another way of encoding the same thing.
I will do that, but the behaviors are not identical. When one articulation is given a placement and the other is not, the two behaviors are:
(1) verovio: assign an automatic placement to the unassigned articulation. If it goes on the same side of the note as another assigned articulation, then determine the stacking of the two (or more) articulations. This could be done in several ways, such as in the order of the <artic>
elements (first one has highest stacking priroity). And/or certain compound articulations such as tenuto-staccato and accent-staccato would automatically be created if these pairs are created on the same side of a note.
(2) Have an automatic deal with it: the converter will not bother with automatic layout, so layout would be simple: articulations unassigned placement would given the same placement as the one which is explicit.
Here is the case that started the discussion:
issue https://github.com/humdrum-tools/verovio-humdrum-viewer/issues/61
The chord on the 2nd beat of the left hand has two articulations: a staccato above and an accent below. The accent needs to be forced below the note, but it is not necessary to force the staccato above, since that is its default position, and the staccato on the next note should be automatic (and above) as well.
Mostly this is a consideration of the semantics of articulation placement. Articulations should not need to be "corrected" under various transpositions of the music. This is important more for orchestral parts versus a sounding score rather than in the case of piano music, of course. As an example, consider that the accent is forced down, and the staccato is forced up, and then the music is transposed down an octave:
This is clearly wrong and looks silly, but that would be the result of hard coding both placements of the articulations.
If the staccato is assigned an automatic placement and the accent is placed below, then one of these two renderings should be the result of transposition:
although this is probably better (but difficult to decide automatically):
Perhaps in this situation, the best semantic encoding would be to have the accent placed on the stem side of the note and the staccato placed automatically, resulting in this rendering of the transposition:
You can move this issue to the backburner now :-)
behaviors are not identical
I know. This is why I said "more or less" the same. (You can currently represent what you would like to see now but if is less flexible (e.g. if you change the clef.) But if we want to allow both
<artic artic"ten stacc"/>
and
<artic artic"ten"/>
<artic artic"stacc"/>
Then we better implement only the later one and then internally transform the first structure into the second one. This is similar to what is happening with <note @accid>
being transformed into `
Here it is https://github.com/rism-ch/verovio/wiki/Low-priority-wish-list (now "Low priority wish list")
When a note contains articulations which have
@place
and no@place
attributes, the layout algorithm of verovio is not aware of both sets of articulations at the same time, and so the articulations are overstriking each other:The algorithm should be aware of all articulations, and merge them after assigning default
@place
values when typesetting, and then merge them into a reasonable stacking order (such as forcing the staccato to be closer to the notes when doing the merge in this case).MEI test data:
Humdrum test data: