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.
process myproc-notes () for o from 0 to 20 by 1/2 fms:note(time: o, dur: 1/2, pitch: 72, part: "0") fms:note(time: o, dur: 1/2, pitch: 48, part: "1") end process myproc-marks () repeat 8 send("fms:mark", dur: 1/2, part: odds(.5, "0", "1"), time: random(40) / 2, marks: {"^"}) end begin with parts = {{:inst "flute" :id "0"} {:inst "tuba" :id "1"}} sprout(list(myproc-notes(), myproc-marks()), *filename*, parts: parts) end |
|
Figure 8.31: Mark Events
If the mark event duration overlaps with more than one note event, than the articulation is applied to all of them.
process myproc-notes () for o from 0 to 20 by 1/2 fms:note(time: o, dur: 1/2, pitch: 72, part: "0") fms:note(time: o, dur: 1/2, pitch: 48, part: "1") end process myproc-marks () repeat 8 send("fms:mark", dur: 1, part: odds(.5, "0", "1"), time: random(40) / 2, marks: {"^"}) end begin with parts = {{:inst "flute" :id "0"} {:inst "tuba" :id "1"}} sprout(list(myproc-notes(), myproc-marks()), *filename*, parts: parts) end |
|
Figure 8.32: Large Duration Mark Events
The voice or voices of a mark event determine to which voice the marks are applied:
process myproc-notes () repeat 41 fms:note(dur: 1/2, pitch: 72, voice: 1) fms:note(dur: 1/2, pitch: 48, voice: 2) wait 1/2 end process myproc-marks () repeat 8 fms:mark(dur: 1/2, voice: odds(.5, 1, 2), time: random(40) / 2, marks: {"^"}) end begin with parts = {{:id "p1" :inst "piano"}} sprout(list(myproc-notes(), myproc-marks()), *filename*, parts: parts) end |
|
Figure 8.33: Voices in Mark Events
Marks events can also have “point” durations of 0, which can only overlap with a single note event (or chord).
process myproc-notes () for o from 0 to 20 by 1/2 fms:note(time: o, dur: 1/2, pitch: 72, part: "0") fms:note(time: o, dur: 1/2, pitch: 48, part: "1") end process myproc-marks () repeat 8 send("fms:mark", dur: 0, part: odds(.5, "0", "1"), time: random(40) / 2, marks: {"^"}) end begin with parts = {{:inst "flute" :id "0"} {:inst "tuba" :id "1"}} sprout(list(myproc-notes(), myproc-marks()), *filename*, parts: parts) end |
|
Figure 8.34: 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.
process myproc-notes () for o from 0 to 10 by 1/2 fms:note(time: o, dur: 1/2, pitch: 72, part: "0") fms:note(time: o, dur: 1/2, pitch: 48, part: "1") end process myproc-marks (part) until elapsed(#t) >= 10 send("fms:mark", dur: 3, part: part, marks: {"(.." "..)"}) wait 5 end begin with parts = {{:inst "flute" :id "0"} {:inst "tuba" :id "1"}} sprout(list(myproc-notes(), myproc-marks("0"), myproc-marks("1")), {0 1 3}, *filename*, parts: parts) end |
|
Figure 8.35: 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.
process myproc-notes () repeat 4 fms:note(dur: 4, pitch: 72, part: "0") fms:note(dur: 4, pitch: 48, part: "1") wait 4 end process myproc-marks (part) until elapsed(#t) >= 10 send("fms:mark", time: elapsed(), dur: 2, part: part, marks: {"<.." "..<"}) send("fms:mark", time: elapsed() + 2, dur: 2, part: part, marks: {">.." "..>"}) wait 4 + 1/2 end begin with sets = {:wedge-canspanone #t :wedge-cantouch #t}, parts = {{:inst "flute" :id "0"} {:inst "tuba" :id "1"}} sprout(list(myproc-notes(), myproc-marks("0"), myproc-marks("1")), {0 1 3}, *filename*, parts: parts) end |
|
Figure 8.36: 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.)
process myproc-notes () repeat 33 fms:note(dur: 1/2, pitch: 72, part: "0") fms:note(dur: 1/2, pitch: 48, part: "1") wait 1/2 end process myproc-marks () with mode = make-cycle({"touch" "overlap" "include"}), dur = make-cycle({ 2 2 5/4}), part = make-cycle({"0" "1"}) repeat 6 fms:mark(dur: next(dur), part: next(part), marks: {"^"}, right: next(mode)) wait 5/2 end begin with parts = {{:inst "flute" :id "0"} {:inst "tuba" :id "1"}} sprout(list(myproc-notes(), myproc-marks()), *filename*, parts: parts) end |
|
Figure 8.37: Changing Overlap Behavior