Hello all,
Some of you may be interested to know that slippery chicken can now generate antescofo~ files.
This isn’t yet part of a release but slippery chicken users who use our svn server or the update-app-src function to get the latest edits can get hold of this now.
Below is the documentation which will form part of the next release.
Best, Michael
slippery-chicken/write-antescofo [ Methods ]
DESCRIPTION
Write an antescofo~ (Arshia Cont’s/IRCAM’s score follower MaxMSP external) score file. This allows you to specify a single player to follow (for now: no polyphonic following) and which players’ events you’d like to be triggered along with this, in the form of MIDI notes (sent via antescofo’s group action commands). Of course this doesn’t imply that you have to use MIDI with antescofo, rather, that you have something that picks up midi note data and uses them (or ignores them) somehow or other. In any case, the MIDI notes sent consist of four messages: the MIDI note (in midi cents e.g. middle C = 6000), the velocity (taken as usual from the amplitude slot of the event), the channel, and the duration in beats. Each may be preceded by a delay, which will be relative to the previous NOTE or group MIDI note.
Rehearsal letters already in the slippery-chicken piece will automatically be written into the antescofo~ file as labels/cues. E.g. if you have rehearsal letter A, it will show up in the antescofo~ file as “letter-A”. Further labels/cues can be added to any slippery-chicken events and these will also be written into the antescofo~ file.
Action messages can also be added to events and thus written into the antescofo~ file. You can push as many messages as you want into this list; they’ll be reversed before writing out so that they occur in the order in which you added them. NB For the part we’re following, we can add messages to rests but if it turns out we added messages to rests in other players’ (i.e. group event parts) these won’t be written to the antescofo~ file.
Bear in mind that if you want to write antescofo~ files without having to work within the usual slippery chicken workflow, you could generate events by any method, then put them into rtm-seq-bar objects before then calling bars-to-sc in order to create a slippery-chicken object by brute force (as it were).
ARGUMENTS
- The slippery-chicken object
- the player who we’ll follow (single player for now, as a symbol)
OPTIONAL ARGUMENTS
keyword arguments:
- :group-players (list of symbols). The players for whom midi-note events will be written in the antescofo file as part of a "group" action. If NIL, then we'll write all players' events except for the player we're following. NB There's no reason why we couldn't include the player we're following in these group commands (for unison playing between live and digital instruments perhaps). The easist way to write group events for all players is to write something like :group-players (players +your-sc-object+) Default = NIL.
- :bar-num-receiver. The MaxMSP receiver name to which bar numbers will be sent for display other other purposes. Default = "antescofo-bar-num"
- :midi-note-receiver. The MaxMSP receiver name to which midi notes will be sent. Default = "midi-note", so a typical group output event could be 0.0 midi-note 6500 12 4 0.6666667
- :file. The name of the file to write. If NIL, then the file name will be created from the slippery-chicken title and placed in (get-sc-config 'default-dir). Default = NIL.
RETURN VALUE
The number of NOTE plus action events we’ve written. We also print to the terminal the number of events and actions, which should correspond to what Antescofo~ prints when it loads the score in MaxMSP
EXAMPLE
;;; Follow the violin part and generate group events for all other parts
(let* ((mini
(make-slippery-chicken
'+mini+
:title "antescofo test"
:ensemble '(((vn (violin :midi-channel 1))
(va (viola :midi-channel 2))
(vc (cello :midi-channel 3))))
:set-palette '((1 ((f3 g3 a3 b3 c4 d4 e4 f4 g4 a4 b4 c5))))
:set-map '((1 (1 1 1)))
:tempo-map '((1 60))
:rthm-seq-palette '((1 ((((4 4) { 3 tq tq tq } +q e (s) s)))))
:rthm-seq-map '((1 ((vn (1 1 1))
(va (1 1 1))
(vc (1 1 1))))))))
;; Adding a label (probably wouldn't need one in bar 1, but to illustrate)
(setf (asco-label (get-event mini 1 1 'vn)) "test-label")
;; start the (fictitious) vocoder when the first cello note in bar 2 is played
(push "max-receiver1 start-vocoder" (asco-msgs (get-event mini 2 1 'vc)))
(write-antescofo mini 'vn :file "/tmp/asco-test.txt"))
–>
******* section (1)
Getting notes for VN
Getting notes for VA
Getting notes for VC
Shortening short, fast leaps…
Shortened 0 large fast leaps
“/tmp/asco-test.txt”
Antescofo~ score written successfully with 15 events and 34 actions.
49
The generated file will begin like this:
; antescofo~ score generated by slippery chicken version
; 1.0.4 (svn revision 4733 2014-01-15 11:27:10)
; at 12:02:06 on Thursday the 8th of May 2014
BPM 60
antescofo-bar-num 1 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
NOTE 6200 0.6666667 test-label
group bar1.1 {
0.0 midi-note 6000 12 2 0.6666667
0.0 midi-note 6400 12 3 0.6666667
}
NOTE 6200 0.6666667
group bar1.2 {
0.0 midi-note 6000 12 2 0.6666667
0.0 midi-note 6400 12 3 0.6666667
}
NOTE 6200 1.6666667
group bar1.3 {
0.0 midi-note 6000 12 2 1.6666667
0.0 midi-note 6400 12 3 1.6666667
}
NOTE 6200 0.5
group bar1.4 {
0.0 midi-note 6000 12 2 0.5
0.0 midi-note 6400 12 3 0.5
}
NOTE 0 0.25
NOTE 6200 0.25
group bar1.5 {
0.0 midi-note 6000 12 2 0.25
0.0 midi-note 6400 12 3 0.25
antescofo-bar-num 2 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
}
NOTE 6200 0.6666667
group bar2.1 {
0.0 midi-note 6000 12 2 0.6666667
0.0 midi-note 6400 12 3 0.6666667
max-receiver1 start-vocoder
}
NOTE 6200 0.6666667
...