Skip to content

Instantly share code, notes, and snippets.

View colinbdclark's full-sized avatar

Colin Clark colinbdclark

  • Institute for Research and Development on Inclusion and Society
  • Toronto, Ontario
View GitHub Profile
@colinbdclark
colinbdclark / record-mic-audio.js
Last active July 21, 2017 16:07
Record an audio buffer from the microphone using Flocking
fluid.defaults("flock.microphoneRecorder", {
gradeNames: "flock.synth",
synthDef: {
ugen: "flock.ugen.writeBuffer",
options: {
duration: 15,
numOutputs: 1
},
buffer: "recording",
@colinbdclark
colinbdclark / ioc-flocking.js
Last active March 13, 2017 14:30
IoC Flocking
fluid.defaults("my.piece", {
gradeNames: "fluid.component",
components: {
enviro: {
type: "flock.enviro",
},
synth: {
type: "my.synth",
@colinbdclark
colinbdclark / a11y-camp-to-welcome-talk.txt
Created November 5, 2016 15:11
Accessibility Camp Toronto 2016 Welcome Talk #a11yTO
Hi everyone, I'm Colin Clark, and I work at the Inclusive Design Research Centre here at OCAD University. I'd like to welcome you to OCAD today. Over the past six years, the IDRC has been honoured to help give Camp a home here, and to be participants in this amazing, diverse, and growing community of people who care about accessibility and inclusive design.
It's awesome to see so many of you here today--there's something very special about Toronto and its commitment to inclusion, and you all are the reason why this city is recognized around the world for its impact in inclusive design. Since we're camping out here at Canada's largest art and design university, I thought I'd reflect for a moment today on the craft and creativity of this accessibility movement we're all a part of.
We know that accessibility isn't just the right thing to do. It's not just our moral responsibility, or our legal obligation, or our social commitment. It is those things, but it's also something more: it's a force for positive ch
@colinbdclark
colinbdclark / kick-drum.js
Created July 2, 2016 16:38
Flocking kick drum sketch
flock.synth({
synthDef: {
ugen: "flock.ugen.sinOsc",
freq: {
ugen: "flock.ugen.envGen",
envelope: {
type: "flock.envelope.adsr",
attack: 0,
decay: 0.2,
@colinbdclark
colinbdclark / buses.js
Last active June 20, 2016 17:44
Example of how to use buses in Flocking
/**********************
* For Flocking 0.1.x:
**********************/
var interconnectBus = flock.enviro.shared.acquireNextBus("interconnect");
var snare = flock.synth({
synthDef: {
ugen: "flock.ugen.out",
bus: interconnectBus,
@colinbdclark
colinbdclark / midi-controller-wiring.js
Created May 11, 2016 22:02
New MIDI controller binding specification, harmonized with the wiring specification format.
fluid.defaults("my.midiController", {
gradeNames: "flock.midi.controller",
components: {
// All "target" declarations are relative to this component.
synthContext: "${myComposition}.band"
},
inputMap: {
noteOn: [
window.s = flock.synth({
synthDef: {
ugen: "flock.ugen.sum",
sources: [
{
ugen: "flock.ugen.filter.moog",
cutoff: {
ugen: "flock.ugen.lfNoise",
mul: 10000,
add: 10000,
@colinbdclark
colinbdclark / flocking-synth-pause.js
Created April 8, 2016 18:10
Pausing a Flocking Synth
var s = flock.synth({
synthDef: {
ugen: "flock.ugen.sinOsc"
}
});
s.enviro.asyncScheduler.once(5, function () {
s.pause();
});
@colinbdclark
colinbdclark / flocking-all-ioc.js
Last active January 28, 2016 22:32
Using Flocking entirely with Infusion IoC
fluid.defaults("flock.test.muzak", {
gradeNames: "fluid.component",
components: {
enviro: {
type: "flock.enviro"
},
scheduler: {
type: "flock.scheduler.async",
@colinbdclark
colinbdclark / electric-piano-synth
Last active November 13, 2015 04:22
Early sketch of electric piano synth for FLOE Chart Authoring sonification tool
fluid.defaults("floe.chartAuthoring.electricPianoBand", {
gradeNames: ["flock.band"],
components: {
midiNoteSynth: {
type: "floe.chartAuthoring.midiNoteSynth"
},
pianoEnvelopeSynth: {
type: "floe.chartAuthoring.pianoEnvelopeSynth"