This SuperCollider package makes it possible to create SuperCollider packages (Quarks) containing plugins written in Faust code. With this, you can distribute plugins written in Faust and make it easy for others to install, compile or uninstall them. It also contains some simple interfaces for the faust
and faust2sc.py
commands used behind the scenes.
This package requires faust version 2.40.0 or higher to work.
If you've never made a SuperCollider package before, read this guide and/or try generating one using this cookiecutter recipe.
If you want to see a finished package that uses this method, see this example Quark.
This package assumes that you have .dsp
faust files in your project in a folder at the root of your project called faust
(if you want to change this, see the help files). Every .dsp
file in this folder will be part of your installation.
In your Quark folder, open up the .quark file and add this package as a dependency eg:
(
name: "mycoolfaustplugins",
summary: "Only the world's coolest plugins",
version: "0.001",
schelp: "MyCoolFaust.schelp",
dependencies: ["https://github.com/madskjeldgaard/faust.quark"], // <----- Add Faust.quark here
license: "GNU GPL v3.0",
copyright: "yourname",
ext_dependency: nil,
url: "https://github.com/yourname/mycoolfaustplugins"
)
With this done, when people install your quark it will automatically download this package along with it.
In your Quark, create a simple class that inherits from the AbstractFaustPackage
class defined in this package:
MyCoolFaust : AbstractFaustPackage {}
From now on, your users can install your plugins like this:
MyCoolFaust.install();
Or uninstall like this:
MyCoolFaust.uninstall();
If you want to automatically compile and install the plugins, you can do the following in your subclass:
MyCoolFaust : AbstractFaustPackage{
*initClass{
this.autoCompileAtStartup()
}
}
With this, after the first class library compilation, Faust.quark will check if the plugins are installed and if not it will install them automatically.
That's it. See the help files for more information.
Open up SuperCollider and evaluate the following line of code:
Quarks.install("https://github.com/madskjeldgaard/faust.quark")