Mark events provide a way to specify marks as independent objects, separate from note or rest events. The marks specified in mark events are attached to the notes they overlap with when FOMUS processes them. For example, a mark event with a time of 2, a duration of 4 and a staccato mark places staccato marks on all notes between times 2 and 6. A single mark events can also represent a spanner object like a slur or phrase mark. Also, a few spanner marks can be inserted into the score independent of note events, allowing, for example, crescendo/decrescendo wedges to start or end at locations other than where notes appear.
The following shows how to add articulation marks and note events separately. The mark events are given durations of 1/2 so that they each overlap precisely with one note event.
(defun notes () (loop for o from 0 to 20 by 1/2 do (fms:note :time o :dur 1/2 :pitch 72 :part "0") (fms:note :time o :dur 1/2 :pitch 48 :part "1"))) (defun marks () (loop repeat 8 do (fms:mark :time (/ (random 40) 2) :dur 1/2 :part (if (< (random 1.0) 0.5) "0" "1") :marks '("^")))) (fms:with-score (:filename *filename* :parts '((:inst "flute" :id "0") (:inst "tuba" :id "1"))) (notes) (marks)) |
|
Figure 7.33: Mark Events
If the mark event duration overlaps with more than one note event, than the articulation is applied to all of them.
(defun notes () (loop for o from 0 to 20 by 1/2 do (fms:note :time o :dur 1/2 :pitch 72 :part "0") (fms:note :time o :dur 1/2 :pitch 48 :part "1"))) (defun marks () (loop repeat 8 do (fms:mark :time (/ (random 40) 2) :dur 1 :part (if (< (random 1.0) 0.5) "0" "1") :marks '("^")))) (fms:with-score (:filename *filename* :parts '((:inst "flute" :id "0") (:inst "tuba" :id "1"))) (notes) (marks)) |
|
Figure 7.34: Large Duration Mark Events
The voice or voices of a mark event determine to which voice the marks are applied:
(defun notes () (loop for o from 0 to 20 by 1/2 do (fms:note :time o :dur 1/2 :pitch 72 :voice 1) (fms:note :time o :dur 1/2 :pitch 48 :voice 2))) (defun marks () (loop repeat 8 do (fms:mark :time (/ (random 40) 2) :dur 1/2 :voice (if (< (random 1.0) 0.5) 1 2) :marks '("^")))) (fms:with-score (:filename *filename* :parts '((:id pno :inst "piano"))) (notes) (marks)) |
|
Figure 7.35: Voices in Mark Events
Marks events can also have “point” durations of 0, which can only overlap with a single note event (or chord).
(defun notes () (loop for o from 0 to 20 by 1/2 do (fms:note :time o :dur 1/2 :pitch 72 :part "0") (fms:note :time o :dur 1/2 :pitch 48 :part "1"))) (defun marks () (loop repeat 8 do (fms:mark :time (/ (random 40) 2) :dur 0 :part (if (< (random 1.0) 0.5) "0" "1") :marks '("^")))) (fms:with-score (:filename *filename* :parts '((:inst "flute" :id "0") (:inst "tuba" :id "1"))) (notes) (marks)) |
|
Figure 7.36: 0 Duration Mark Events
Mark events that contain begin or end marks insert the marks into the first and last note events that are overlapped by the mark event. This effectively creates a spanner that spans the duration (or approximate duration) of the mark event.
(defun notes () (loop for o from 0 to 10 by 1/2 do (fms:note :time o :dur 1/2 :pitch 72 :part "0") (fms:note :time o :dur 1/2 :pitch 48 :part "1"))) (defun marks () (loop for basetime from 0 below 10 by 5 do (fms:mark :time (+ basetime 1) :dur 3 :part "0" :marks '("(.." "..)")) (fms:mark :time (+ basetime 3) :dur 3 :part "1" :marks '("(.." "..)")))) (fms:with-score (:filename *filename* :parts '((:inst "flute" :id "0") (:inst "tuba" :id "1"))) (notes) (marks)) |
|
Figure 7.37: Spanners in Mark Events
When you specify certain spanners such as crescendo/decrescendo wedges with mark events, they are placed in the score “detached” from note events.
In other words, the beginnings and ends of spanners entered this way don't necessarily correspond to the locations of note events.
FOMUS accomplishes this by placing the detached spanner marks in an extra, invisible voice in the output file.
This behavior can be turned off using the detach
setting.
(defun notes () (loop for o from 0 to 12 by 4 do (fms:note :time o :dur 4 :pitch 72 :part "0") (fms:note :time o :dur 4 :pitch 48 :part "1"))) (defun marks () (loop for basetime from 0 below 10 by (+ 4 1/2) do (fms:mark :time (+ basetime 1) :dur 2 :part "0" :marks '("<.." "..<")) (fms:mark :time (+ basetime 1 2) :dur 2 :part "0" :marks '(">.." "..>")) (fms:mark :time (+ basetime 3) :dur 2 :part "1" :marks '("<.." "..<")) (fms:mark :time (+ basetime 3 2) :dur 2 :part "1" :marks '(">.." "..>")))) (fms:with-score (:filename *filename* :sets '(:wedges-canspanone t :wedges-cantouch t) :parts '((:inst "flute" :id "0") (:inst "tuba" :id "1"))) (notes) (marks)) |
|
Figure 7.38: Detached Spanners
By default, a mark event must at least partially overlap a note event for that note event to receive a mark.
This behavior can be changed via the settings left
and right
, which correspond to the onset and offset of a mark event.
Either setting can be set to ‘touch’, ‘overlap’ or ‘include’
to specify that a mark event inserts marks into note events that either touch, overlap, or are completely enclosed within.
(These settings don't affect mark events with 0 durations.)
(defun notes () (loop for o from 0 to 16 by 1/2 do (fms:note :time o :dur 1/2 :pitch 72 :part "0") (fms:note :time o :dur 1/2 :pitch 48 :part "1"))) (defun marks () (loop for o from 0 to 20 by 5/2 for mode in '("touch" "overlap" "include" "touch" "overlap" "include") for dur in '( 2 2 5/4 2 2 5/4) for part = t then (not part) do (fms:mark :time o :dur dur :part (if part "0" "1") :marks '("^") :right mode))) (fms:with-score (:filename *filename* :parts '((:inst "flute" :id "0") (:inst "tuba" :id "1"))) (notes) (marks)) |
|
Figure 7.39: Changing Overlap Behavior