SuperCollider is an audio/music synthesis environment: a combination of an audio-centric programming language and a highly efficient synthesis server. Website here: http://supercollider.sourceforge.net/
Here's how I installed in on default Xandros (i.e. not even in “advanced” mode):
In order to make it easy to add the required software, follow these instructions: Adding Additional Software Repositories
I installed these things by starting a command window (Ctrl+Alt+T) then typing “sudo synpatic” to launch the graphical interface for installing software.
(i.e. things for compiling software. I installed the build-essential package for this; some more detailed description at Installing Development Tools
JACK is a very widely-used audio infrastructure for linux. I installed 4 separate packages:
Some other packages are required, here's what I installed:
You can download the source-code from Sourceforge. Alternatively you can directly get it from the Subversion repository (this gets the latest bleeding-edge version):
svn co https://supercollider.svn.sourceforge.net/svnroot/supercollider/trunk SuperCollider3
This creates a folder “SuperCollider3” and downloads the source code into it; takes 30 secs or so.
The “scons” system can build SuperCollider in various configurations (use “scons -h” to see the available options). However, I just did this:
cd SuperCollider3 scons sudo scons install
The “scons” line does the compilation, and takes about 5 minutes. The last line installs SuperCollider, and takes about 30 seconds.
SwingOSC is a Java-based GUI system that works nicely with SuperCollider to let you build your own GUIs. You don't need it, it's totally optional, but kinda nice. Download site inc install instructions are at http://www.sciss.de/swingOSC/
Here's how I installed it: after unzipping the download I moved it to /usr/local/SwingOSC - but then, to make sure that SuperCollider could access the SwingOSC-specific files, I created a symlink from SuperCollider's extensions directory to the extensions that SwingOSC provides:
sudo ln -s /usr/local/SwingOSC/SuperCollider /usr/local/share/SuperCollider/Extensions/SwingOSC
In order to make sure SuperCollider connects correctly to SwingOSC I edited my SuperCollider startup file (vim /home/user/.sclang.sc ) and added the following lines:
GUI.swing; SwingOSC.program = "/usr/local/SwingOSC/build/SwingOSC.jar"; g = SwingOSC.default; g.boot;
The final line makes the GUI manager boot automatically when I start SuperCollider.
Firstly make sure you've got jack running. I started it by running this command:
sudo jackstart --realtime --timeout 1000 -d alsa -r 44100 --period 256 -n 4 &
Then you can run the Linux test script (to make some noise) by typing:
sudo sclang linux/examples/onetwoonetwo.sc
That runs SuperCollider from the command-line. Press Ctrl-C when you want it to stop.
Once you've got that working you probably want to use SuperCollider's emacs interface. First, you need to set up a configuration file. Create one in root's homedir by running (eg):
sudo nano /root/.emacs
Type in:
(require 'sclang)
(note that there is only one single quote). Save the file and exit.
Launch SuperCollider by typing:
sudo emacs -sclang
It's unfortunate that sudo is needed, but the Eee doesn't have the “real-time kernel patches” which would allow non-sudo processes to run glitch-free real-time audio threads.
NOTE: (edit by nescivi), using these parameters for JACK:
jackd -p128 -dalsa -r44100 -p2048 -n4
give quite glitch free playback even without starting things as root. Also editing the /etc/security/limits.conf with proper settings for the audio group helps:
@audio - rtprio 99 @audio - nice -10 @audio - memlock 256000
NOTE (edit by donnek): Although the above allows the emacs interface to be launched, it does not work properly. If you boot SuperCollider's audio engine by typing in:
s.boot
and, keeping the cursor in that line, Ctrl-C, Ctrl-C, and then paste in (eg):
(
{
RLPF.ar(
in: Saw.ar([200, 202], 0.15),
freq: Lag.kr(LFNoise0.kr(4, 700, 1100), 0.8),
rq: 0.05
)
}.play
)
and run it (by double-clicking on the opening round-bracket to highlight the block, and then Ctrl-C, Ctrl-C) you get:
unmatched ')'
in file 'selected text' line 1 char 1
ERROR: Parse error
in file 'selected text'
line 1 char 1:
)*
---------------------------------------------
ERROR: Command line parse failed
nil
which means that only the line, instead of the whole block, has been evaluated. It's unclear what the problem is here. Any suggestions welcome!
(edit by nescivi) Executing a block of code is done with C-c C-d. With transient-mark-mode turned on, you can also use C-c C-c for code block execution. In the SClang menu in emacs you can find other options for code evaluation.
Now the fun begins. Not sure what's best to recommend, but here are a couple of tutorial resources:
This text is copied from a tutorial by Dan Stowell at http://mcld.co.uk/supercollider/eee/ , with permission from the author. Additions by nescivi (Marije Baalman)