Menu

Elements and Attributes

Niko Beer Maja Hartwig

Elements and Attributes

MEISE is a tool, which will be improved and enriched with more and new features continuously. Because of the broad range of the MEI format, MEISE currently supports only a part of MEI's complete scope. MEI is focused on the encoding of documents in the context of musicology and libraries, and in particular on the representation of primary source materials for research and analysis. The model accomplishes three principal tasks: First the schema breaks down the content of music notation documents into data fields or categories of information called 'elements'. All of these elements are named, defined and described in the MEI Tag Library.

Second, the tag library identifies and defines attributes associated with those elements. Attributes are characteristics or properties that further refine the element. Last, and perhaps most importantly, the tag library expresses the schema structure by explaining the relationship between elements, specifying where the elements may be used and describing how they may be modified by attributes (see MEI 2013 Guidelines).

The following tables represent the elements and attributes of the MEI schema which currently are supported to be rendered by MEISE.

Elements |
---- | ----
<accid> | accidentals
<app> | apparatus, requires one or more readings
<artic> | articulation, e.g. stacc, pizz, etc.
<beam> | beams, container for beamed events
<chord> | chord, contains two or more notes
<dynam> | dynamics, indication of the volume of music, supported by MEISE only with the @startid and @endid
<ending> | alternative ending for a repeated passage
<fermata> | fermate indicates longer values of an event
<hairpin> | hairpin, indicates dynamics, supported by MEISE only with @startid and @endid
<key> | key, gives information about tonal center and mode
<layer> | layer, independent stream within a staff (often called voice)
<measure> | measure, unit of musical time
<mdiv> | musical division, contains musical text
<mRest> | (measure rest) – complete measure rest in any meter
<mSpace> | space for complete measure
<note> | note, event within a layer
<rdg> | reading within an apparatus
<rest> | rest, event within layer
<score> | score, container for musical text
<scoreDef> | score definition, information about key, meter, etc.
<slur> | slur, performance technique (in German: Bindebogen)
<staff> | staff = system in a score
<staffDef> | staff definition, information about key, meter, clefs
<staffGrp> | group of staves, requires one or more staffDefs
<tie> | tie, performance technique (in German: Haltebogen)

Attributes |
---- | ----
@accid | accidentals within <note>, e.g. s, f, ss, ff, etc. (sharp, flat, double-s/f etc.)
@artic | articulation within <note>, eg. staccato (@artic = stacc)
@clef.line | within <staffDef> or <scoreDef>
@clef.shape | within <staffDef> or <scoreDef>
@dot | within <note> and <chord>
@dur | duration, within <note> and <chord>
@label | e.g. within <staffDef>, gives the staff an arbitrary name
@oct | octave, within <note>
@pname | pitchname, within <note>, e.g. a, b, c, d, etc.
@stem.dir | stem direction, within <note> (up or down)
@stem.len | stem length, within <note> (default value is 19)
@xml:id | identifies an element uniquely, referring to an event requires #xml:id

Example of an MEI scoreDef

<scoreDef key.sig="1s" meter.count="2" meter.unit="4">
    <staffGrp>
        <staffDef n="1" label="Singstimme" clef.shape="G" clef.line="2"/>
        <staffGrp symbol="brace" label="Pianoforte" barthru="true">
            <staffDef n="2" clef.line="2" clef.shape="G"/>
            <staffDef n="3" clef.shape="F" clef.line="4"/>
        </staffGrp>
    </staffGrp>
</scoreDef>

Example of a complete MEI measure

<measure n="2" xml:id="op79_20_m2">
    <staff n="1" xml:id="op79_20_m2s1">
        <layer n="1">
            <note pname="a" oct="4" dur="8" stem.dir="up" xml:id="op79_20_m2s1l1e1">
                <verse n="1">
                    <syl wordpos="i" con="u">die</syl>
                </verse>
            </note>
            <note pname="g" oct="4" dur="8" stem.dir="up" xml:id="op79_20_m2s1l1e2">
                <verse n="1">
                    <syl wordpos="t">sen</syl>
                </verse>
            </note>
            <note pname="c" oct="5" dur="8" stem.dir="down" dots="1"
               xml:id="op79_20_m2s1l1e3">
                <verse n="1">
                    <syl wordpos="i" con="u">trü</syl>
                </verse>
            </note>
            <note pname="b" oct="4" dur="16" stem.dir="down"
               xml:id="op79_20_m2s1l1e4">
                <verse n="1">
                    <syl wordpos="t">ben</syl>
                </verse>
            </note>
        </layer>
    </staff>
    <staff n="2" xml:id="op79_20_m2s2">
        <layer n="1">
            <rest dur="4"/>
            <rest dur="8"/>
            <note pname="g" accid="s" stem.dir="up" dur="8"
              xml:id="op79_20_m2s2l1e1"/>
        </layer>
        <layer n="2">
            <rest dur="16"/>
            <beam>
                <note pname="d" oct="4" dur="16" stem.dir="down"
                    xml:id="op79_20_m2s2l2e1"/>
                <note pname="g" oct="4" dur="16" stem.dir="down"
                    xml:id="op79_20_m2s2l2e2"/>
                <note pname="f" accid="n" oct="4" dur="16" stem.dir="down"
                    xml:id="op79_20_m2s2l2e3"/>
            </beam>
            <beam>
                <note pname="e" oct="4" dur="16" stem.dir="down"
                    xml:id="op79_20_m2s2l2e4"/>
                <note pname="f" oct="4" dur="16" stem.dir="down"
                    xml:id="op79_20_m2s2l2e5"/>
                <note pname="e" oct="4" dur="16" stem.dir="down"
                    xml:id="op79_20_m2s2l2e6"/>
                <note pname="d" oct="4" dur="16" stem.dir="down"
                    xml:id="op79_20_m2s2l2e7"/>
            </beam>
        </layer>
    </staff>
    <staff n="3" xml:id="op79_20_m2s3">
        <layer n="1">
            <rest dur="4"/>
            <chord dur="4" stem.dir="up" xml:id="op79_20_m2s3l1e1">
                <note pname="e" oct="2"/>
                <note pname="e" oct="3"/>
            </chord>
        </layer>
    </staff>
    <slur staff="2" curvedir="below" startid="#op79_20_m2s2l2e1"
        endid="#op79_20_m2s2l2e7"/>
    <slur staff=" 2" curvedir="above" startid="#op79_20_m2s2l1e1"
        endid="#op79_20_m3s2l1e2"/>
    <tie staff="2" curvedir="above" startid="#op79_20_m2s2l1e1"
        endid="#op79_20_m3s2l1e1"/>
    <tie staff="3" curvedir="above" startid="#op79_20_m2s3l1e1"
        endid="#op79_20_m3s3l1e1"/>
    <tie staff="3" curvedir="below" startid="#op79_20_m2s3l1e1"
        endid="#op79_20_m3s3l1e1"/>
</measure>

MEI allows the encoding of events both as elements or attributes in some cases. The following example illustrates a slur first encoded as an element and second as an attribute. MEISE illustrates both capabilities.

Example of a slur

<measure n="1" xml:id="d1e15">
    <staff n="1">
        <layer n="1">
            <rest xml:id="d1e41" dur="4"/>
            <note xml:id="d1e50" pname="c" oct="4" dur="4" stem.dir="up"/>
            <note xml:id="d1e72" pname="e" oct="4" dur="4" dur.ges="2p" stem.dir="up"/>                          
            <note xml:id="d1e96" pname="a" oct="4" dur="4" dur.ges="2p" stem.dir="up"/>
        </layer>
    </staff>
    <staff n="2">
        <layer>
            <!-- musical content -->
        </layer>
    </staff>
    <staff n="3">
        <layer n="1">
            <!-- musical content -->
        </layer>
    </staff>
    <slur tstamp="1.25" curvedir="above" startid="#d1e161" endid="#d1e356"
        staff="2 3" tstamp2="0m+2.25"/>
</measure>
<measure n="2" xml:id="d1e375">
    <staff n="1">
        <layer n="1">
            <note xml:id="d1e381" pname="d" oct="5" dur="4"
                 stem.dir="down" slur="i1"/>
            <note xml:id="d1e402" pname="c" oct="5" dur="4"
                 stem.dir="down" accid.ges="s" slur="m1"/>
            <note xml:id="d1e420" pname="b" oct="4" dur="4"
                 stem.dir="down" slur="m1"/>                          
            <note xml:id="d1e441" pname="a" oct="4" dur="4" dur.ges="2p"
                 stem.dir="up" slur="t1"/>
        </layer>
    </staff>
    <staff n="2">
        <layer n="1">
            <!-- musical content -->
        </layer>
    </staff>
    <staff n="3">
        <layer n="1">
            <!-- musical content -->
        </layer>
    </staff>
</measure>


Related

Wiki: Home

MongoDB Logo MongoDB