Clamps Packages
CM Extensions
General
Common Music's infrastructure uses the events method to output events1. events is a multiple dispatch method, dispatching different event classes to different output backends. The first argument of events is an instance of an event class, the second argument is either an instance of class <incudine-stream> indicating realtime output, or a string denoting a filename. The filename extension is used for the dispatch of the output backend.
The event classes defined by CM 2.12 for output are2:
- MIDI events of all types
- OSC events for SuperCollider
- CLM events for CLM
The supported output types in CM 2.12 and their class/filename extensions are:
Output type | Class or Filename extension |
---|---|
Realtime | <incudine-stream> |
MIDI file | ".midi", ".mid" |
SuperCollider file | ".osc" |
SCO file | ".sco" |
CMN file | ".cmn" |
CLM file | ".clm" |
Soundfile | ".aiff", ".wav" |
EPS file | ".eps" |
FOMUS file | ".ly", ".xml", ".dat" |
The SCO file format in Common Music seems to have been only partially implemented.
Below is an overview of the implemented output methods for the different event types and output backends in Common Music:
MIDI file | SC file | CMN file | EPS file | FOMUS file | Soundfile | CLM file | Realtime | |
---|---|---|---|---|---|---|---|---|
MIDI | x | x | x | x | ||||
OSC | x | x | ||||||
CMN | x | x | x | |||||
CLM | x | x | x |
The CMN type and output file types (".cmn" and ".eps") and the CLM types are currently not actively supported in Clamps, as CMN is replaced in favor of FOMUS and CLM is emulated in cuda-clm and its functionality provided by Incudine. Both systems should nevertheless continue to work to the extent they worked in CM 2.12.
Clamps extends the event classes of CM by the following event classes:
- sfz (see cm-sfz)
- poolevt (see cm-poolevt)
- cm-fudi
In addition Clamps extends the available output backends of Common Music by a SVG backend, using the filename extension ".svg".
The realtime backend in Clamps uses the special variable
*rts-out*. Its value is an <incudine-stream>. When a MIDI event
is sent to this stream, clamps automatically dispatches it to the
midi-output of *rts-out*
(by default this is *midi-out1*
). If
instead the output is realized using incudine dsps, as in the case
of sfz output, the dsps are automatically scheduled and
instantiated.
Below is an overview of the implemented output methods for the different event types and output backends in Clamps:
MIDI file | SC file | FOMUS file | SVG file | Realtime | |
---|---|---|---|---|---|
MIDI | x | x | x | x | |
OSC | x | x | x | ||
SFZ | x | x | x | ||
Poolevt | x | x | |||
FUDI | x |