| 1 | <HTML> |
| 2 | <HEAD><TITLE> |
| 3 | Chord-at-a-time input style |
| 4 | </TITLE></HEAD> |
| 5 | <BODY> |
| 6 | <P> |
| 7 | <A HREF="tuplets.html"><-- previous page</A> |
| 8 | |
| 9 | <A HREF="index.html">Table of Contents</A> <A HREF="bars.html">next page --></A> |
| 10 | </P> |
| 11 | |
| 12 | <H2> |
| 13 | Chord-at-a-time input style |
| 14 | </H2> |
| 15 | <P> |
| 16 | There is an alternate input style, in which you enter music |
| 17 | a chord at a time, rather than a voice at a time. In this style, the |
| 18 | specification before the colon gives one or more patterns that tells |
| 19 | how to map notes to staffs and voices. |
| 20 | </P> |
| 21 | <P> |
| 22 | Suppose you want to print some |
| 23 | music in a style which is common for many traditional hymns: |
| 24 | it is to be printed on two staffs, each staff will always have |
| 25 | exactly two notes, and the rhythm is exactly the same for all voices. |
| 26 | With chord at a time input, you specify, for each note in a chord, |
| 27 | which staff and voice to map that note. Since there are four notes in |
| 28 | each chord, there will be four mappings listed. You want the bottom |
| 29 | two notes to get mapped to staff 2, and the top two notes to staff 1. |
| 30 | This is shown as |
| 31 | <BR><PRE> |
| 32 | // Bass to staff 2 voice 1 |
| 33 | // | Tenor to staff 2 voice 1 |
| 34 | // | | Alto to staff 1 voice 1 |
| 35 | // | | | Soprano to staff 1 voice 1 |
| 36 | [ 2 1; 2 1; 1 1; 1 1 ] |
| 37 | </PRE><BR> |
| 38 | Each item in the semicolon-separated list tells how to map one note. |
| 39 | So the first note in each chord will get mapped to staff 2 voice 1. |
| 40 | The second note in each chord will also get mapped to staff 2 voice 1. |
| 41 | The third and fourth notes will get mapped to staff 1 voice 1. |
| 42 | </P> |
| 43 | <P> |
| 44 | Since voice 1 is, as always, the default, this could be written more |
| 45 | compactly as just: |
| 46 | <BR><PRE> |
| 47 | [ 2; 2; 1; 1 ] |
| 48 | </PRE><BR> |
| 49 | If you wanted to input notes from top to bottom instead |
| 50 | (in soprano-alto-tenor-bass order, rather than bass-tenor-alto-soprano order), |
| 51 | you could use: |
| 52 | <BR><PRE> |
| 53 | // Soprano |
| 54 | // Alto |
| 55 | // Tenor |
| 56 | // Bass |
| 57 | [ 1; 1; 2; 2 ] |
| 58 | </PRE><BR> |
| 59 | If you wanted to use two separate voices on each staff (going |
| 60 | back to bottom-to-top order), you could specify: |
| 61 | <BR><PRE> |
| 62 | // Bass to staff 2 voice 2 |
| 63 | // | Tenor to staff 2 voice 1 |
| 64 | // | | Alto to staff 1 voice 2 |
| 65 | // | | | Soprano to staff 1 voice 1 |
| 66 | [ 2 2; 2 1; 1 2; 1 1 ] |
| 67 | </PRE><BR> |
| 68 | </P> |
| 69 | <P> |
| 70 | Now let's put these mappings with music data. |
| 71 | <BR><PRE> |
| 72 | score |
| 73 | staffs=2 |
| 74 | vscheme=2f |
| 75 | staff 2 |
| 76 | clef=bass |
| 77 | |
| 78 | music |
| 79 | |
| 80 | [ 2; 2; 1; 1 ] : facf;dgfb;2cgec+; |
| 81 | bar |
| 82 | |
| 83 | [ 1 1; 1 2; 2 1; 2 2 ] : fcaf;bfgd;2c+egc; |
| 84 | bar |
| 85 | </PRE><BR> |
| 86 | <IMG SRC="mugex31.gif" ALT="Picture of Mup output"><BR> |
| 87 | In the first measure, the first two notes listed in each chord are mapped |
| 88 | to staff 2, voice 1, while the third and fourth notes listed in each chord |
| 89 | are mapped to staff 1 voice 1. In the second measure, two voices are |
| 90 | used and notes are entered in descending order. Note that each note takes |
| 91 | on the correct default octave for whichever staff it is mapped to. |
| 92 | </P> |
| 93 | <P> |
| 94 | It is also possible to use rests or spaces for some of the voices. |
| 95 | <BR><PRE> |
| 96 | score |
| 97 | key=3& |
| 98 | vscheme=2f |
| 99 | |
| 100 | music |
| 101 | |
| 102 | [ 1 2; 1 1 ]: rb; eg; ca; gr; |
| 103 | bar |
| 104 | |
| 105 | [ 1 2; 1 1 ]: er; sr; 8sf; se; 4sg; |
| 106 | bar |
| 107 | </PRE><BR> |
| 108 | <IMG SRC="mugex32.gif" ALT="Picture of Mup output"><BR> |
| 109 | </P> |
| 110 | <P> |
| 111 | Chord attributes and interchord attributes (like tie, slur, xnote, |
| 112 | len, and alt) can be specified just like |
| 113 | for voice-at-a-time input. Note attributes (like ? and ~) apply to |
| 114 | the note wherever it gets mapped, and items that apply to the chord as |
| 115 | a whole will be applied to all the notes. |
| 116 | <BR><PRE> |
| 117 | [1 2; 1 1] : [cue; xnote; len 6] b-e; [with > ] ce& slur; dg~; c?g; |
| 118 | </PRE><BR> |
| 119 | <IMG SRC="mugex33.gif" ALT="Picture of Mup output"><BR> |
| 120 | </P> |
| 121 | <P> |
| 122 | It is possible to map a note to more than one place by using ranges, |
| 123 | and/or by giving a list of staffs and voices, |
| 124 | separated by ampersands. This may be useful, |
| 125 | for example, if several voices are in unison. |
| 126 | In the next example, the first note in each chord will be mapped to voice |
| 127 | 1 of staffs 1 through 3, as well as to voice 2 of staff 1, while the |
| 128 | second note in each chord will be mapped to voice 2 of staffs 2 and 3. |
| 129 | <BR><PRE> |
| 130 | [ 1-3 1 & 1 2; 2-3 2 ] : ec;fd;ge;af; |
| 131 | </PRE><BR> |
| 132 | <IMG SRC="mugex34.gif" ALT="Picture of Mup output"><BR> |
| 133 | </P> |
| 134 | <P> |
| 135 | It is also possible to specify more than one bracketed mapping. |
| 136 | Each must include a mapping for a different number of notes. |
| 137 | So, for example, if some chords in a measure have two notes and |
| 138 | others have three, you can define two maps: one for two notes, |
| 139 | and one for three. The example below demonstrates placing alto |
| 140 | and soprano as two voices on one staff, but sometimes the alto |
| 141 | part splits. |
| 142 | <BR><PRE> |
| 143 | // For chords with two notes, |
| 144 | // map the first to staff 1 voice 2 (alto), |
| 145 | // and the second to staff 1 voice 1 (soprano). |
| 146 | // For chords with three notes, |
| 147 | // map the first two notes to staff 1 voice 2 |
| 148 | // (first and second alto part), |
| 149 | // and the third to staff 1 voice 1 (soprano). |
| 150 | [ 1 2; 1 1 ] [ 1 2; 1 2; 1 1 ]: cec+;df;eg;a-fc+; |
| 151 | </PRE><BR> |
| 152 | <IMG SRC="mugex35.gif" ALT="Picture of Mup output"><BR> |
| 153 | If mappings of different chords need to vary by something other than |
| 154 | the number of notes in the chord, then you will have to use |
| 155 | the voice-at-a-time input style. |
| 156 | </P> |
| 157 | <P> |
| 158 | Since the mapping specifications can get rather complex, |
| 159 | and they may be used many times during a song, |
| 160 | it is usually best to define |
| 161 | <A HREF="macros.html">macros</A> |
| 162 | for them, and possibly even put the macro definitions in |
| 163 | <A HREF="include.html">an "include" file.</A> |
| 164 | </P> |
| 165 | <P> |
| 166 | You can use the different input styles in different measures of a single |
| 167 | song, and use different mappings in different measures. |
| 168 | You can even mix the two input styles within a measure, |
| 169 | but a given staff/voice |
| 170 | can only appear on one line of input per measure. So, for example, |
| 171 | you could choose to input staffs 1 and 2 of a song in chord-at-a-time |
| 172 | input style, and staff 3 in voice-at-a-time style. |
| 173 | </P> |
| 174 | <HR><P> |
| 175 | <A HREF="tuplets.html"><-- previous page</A> <A HREF="index.html">Table of Contents</A> <A HREF="bars.html">next page --></A> |
| 176 | </P> |
| 177 | </BODY></HTML> |