SourceForge.net Logo

2.10. Polyphony

To represent several voices in staff there must be a way to move to the start of a measure to enter a second voice. The goBack and goFwd elements are intended to this, by allowing to move the internal time counter to the desired point so that more notes/rests, layered over existing ones, can be entered.

[30]goBack::= (goBack { start | Expression | [duration] } )  
[31]goFwd::= (goBack { end | Expression | [duration] } )  

were duration is the number of 256th notes to move forward or backwards (one quarter note equals 64 256th notes), and expression is an algebraic expression, formed by numbers, note duration letters and the plus and minus signs, to indicate the duration to move forward or backwards. Examples of expressions are:

3q+e  -> Three quarter notes plus one eighth note;
         it is equivalent to a duration of 3x64+32 = 224,
         that is, 224 notes of 256th type.
q     -> A quarter note.
q+e   -> A quarter note plus an eight note, that is,
         a quarter dotted note.

Constants start and end indicates to move to the start or the end of current measure, respectively.

[Important]Important
goBack and goFwd can only be used to move inside a measure.

Note that a goFwd element behaves like an invisible rest.

For example, following score is generated by next code:

(score
   (vers 1.5)(language en iso-8859-1)
   (instrument
      (musicData
        (clef bass)
        (key e)
        (time 4 4)
        (n g3 q)
        (n a3 q)
        (n g3 q)
        (n e3 q)
        //go back to a3 note to add a second voice
        (goBack 128)
        (n e4 e. (stem up))
        (n d4 s)
        (barline)
      )
   )
)