Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add invisible barline for mid-measure key change to C/a #25

Open
bel28kent opened this issue Aug 17, 2023 · 1 comment
Open

Add invisible barline for mid-measure key change to C/a #25

bel28kent opened this issue Aug 17, 2023 · 1 comment
Labels
hum2mei This issue is caused by the necessary conversion of humdrum data to mei for vhv rendering.

Comments

@bel28kent
Copy link
Owner

          Mid measure key signatures are implemented in commit https://github.com/rism-digital/verovio/commit/fdf041393f016d6d2430e3b20f0076df559ea041

Example:

**kern
*M4/4
*k[f#]
=1
1c
=2
2d
*k[b-]
2e
=
*-

Rendering:

Screenshot 2023-08-17 at 13 22 39
Click to view MEI conversion of above Humdrum data
<?xml version="1.0" encoding="UTF-8"?>
<?xml-model href="https://music-encoding.org/schema/dev/mei-all.rng" type="application/xml" schematypens="http://relaxng.org/ns/structure/1.0"?>
<?xml-model href="https://music-encoding.org/schema/dev/mei-all.rng" type="application/xml" schematypens="http://purl.oclc.org/dsdl/schematron"?>
<mei xmlns="http://www.music-encoding.org/ns/mei" meiversion="5.0.0-dev">
 <meiHead>
  <fileDesc>
   <titleStmt>
    <title />
   </titleStmt>
   <pubStmt />
  </fileDesc>
  <encodingDesc>
   <appInfo>
    <application isodate="2023-08-17T13:23:10" version="3.17.0-dev-ffd96fd">
     <name>Verovio</name>
     <p>Transcoded from Humdrum</p>
    </application>
   </appInfo>
  </encodingDesc>
  <workList>
   <work>
    <title />
   </work>
  </workList>
 </meiHead>
 <music>
  <body>
   <mdiv xml:id="m9xt05d">
    <score xml:id="s1ut797s">
     <scoreDef xml:id="s1so24fo" midi.bpm="400.000000">
      <staffGrp xml:id="s1oq43hn">
       <staffDef xml:id="staffdef-L1F1" n="1" lines="5">
        <clef xml:id="c1rb3gbm" shape="G" line="2" />
        <keySig xml:id="keysig-L3F1" sig="1s" />
        <meterSig xml:id="metersig-L2F1" count="4" unit="4" />
       </staffDef>
      </staffGrp>
     </scoreDef>
     <section xml:id="section-L1F1">
      <measure xml:id="measure-L1" n="1">
       <staff xml:id="staff-L1F1" n="1">
        <layer xml:id="layer-L1F1N1" n="1">
         <note xml:id="note-L5F1" dur="1" oct="4" pname="c" accid.ges="n" />
        </layer>
       </staff>
      </measure>
      <measure xml:id="measure-L6" n="2">
       <staff xml:id="staff-L6F1N1" n="1">
        <layer xml:id="layer-L6F1N1" n="1">
         <note xml:id="note-L7F1" dur="2" oct="4" pname="d" accid.ges="n" />
         <keySig xml:id="keysig-L8F1" type="mid-measure" sig="1f" />
         <note xml:id="note-L9F1" dur="2" oct="4" pname="e" accid.ges="n" />
        </layer>
       </staff>
      </measure>
     </section>
    </score>
   </mdiv>
  </body>
 </music>
</mei>

Note that when the mid-measure key signature changes to C major/A minor, the cancellation naturals are not shown yet:

**kern
*M4/4
*k[f#]
=1
1c
=2
2d
*k[]
2e
=
*-

Rendering:

Screenshot 2023-08-17 at 13 24 35
Click to view MEI conversion of above Humdrum data
<?xml version="1.0" encoding="UTF-8"?>
<?xml-model href="https://music-encoding.org/schema/dev/mei-all.rng" type="application/xml" schematypens="http://relaxng.org/ns/structure/1.0"?>
<?xml-model href="https://music-encoding.org/schema/dev/mei-all.rng" type="application/xml" schematypens="http://purl.oclc.org/dsdl/schematron"?>
<mei xmlns="http://www.music-encoding.org/ns/mei" meiversion="5.0.0-dev">
 <meiHead>
  <fileDesc>
   <titleStmt>
    <title />
   </titleStmt>
   <pubStmt />
  </fileDesc>
  <encodingDesc>
   <appInfo>
    <application isodate="2023-08-17T13:25:15" version="3.17.0-dev-ffd96fd">
     <name>Verovio</name>
     <p>Transcoded from Humdrum</p>
    </application>
   </appInfo>
  </encodingDesc>
  <workList>
   <work>
    <title />
   </work>
  </workList>
 </meiHead>
 <music>
  <body>
   <mdiv xml:id="m1s4j3x3">
    <score xml:id="s1c5xu57">
     <scoreDef xml:id="srk0660" midi.bpm="400.000000">
      <staffGrp xml:id="spxsrhh">
       <staffDef xml:id="staffdef-L1F1" n="1" lines="5">
        <clef xml:id="c1o64pwg" shape="G" line="2" />
        <keySig xml:id="keysig-L3F1" sig="1s" />
        <meterSig xml:id="metersig-L2F1" count="4" unit="4" />
       </staffDef>
      </staffGrp>
     </scoreDef>
     <section xml:id="section-L1F1">
      <measure xml:id="measure-L1" n="1">
       <staff xml:id="staff-L1F1" n="1">
        <layer xml:id="layer-L1F1N1" n="1">
         <note xml:id="note-L5F1" dur="1" oct="4" pname="c" accid.ges="n" />
        </layer>
       </staff>
      </measure>
      <measure xml:id="measure-L6" n="2">
       <staff xml:id="staff-L6F1N1" n="1">
        <layer xml:id="layer-L6F1N1" n="1">
         <note xml:id="note-L7F1" dur="2" oct="4" pname="d" accid.ges="n" />
         <keySig xml:id="keysig-L8F1" type="mid-measure" sig="0" cancelaccid="before" />
         <note xml:id="note-L9F1" dur="2" oct="4" pname="e" accid.ges="n" />
        </layer>
       </staff>
      </measure>
     </section>
    </score>
   </mdiv>
  </body>
 </music>
</mei>

This is related to issue rism-digital/verovio#3497 (comment)

To make visible in the meantime, add an invisible barline as mentioned above.

Originally posted by @craigsapp in humdrum-tools/verovio-humdrum-viewer#830 (comment)

@bel28kent bel28kent added the hum2mei This issue is caused by the necessary conversion of humdrum data to mei for vhv rendering. label Sep 21, 2023
@bel28kent bel28kent changed the title op07_no02: Mid-measure key signature change, bar 80 Add invisible barline for mid-measure key change to C/a Sep 21, 2023
@bel28kent
Copy link
Owner Author

Pieces to check-up on when issue is resolved:

  • op07_no02

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hum2mei This issue is caused by the necessary conversion of humdrum data to mei for vhv rendering.
Projects
None yet
Development

No branches or pull requests

1 participant