View this PageEdit this PageUploads to this PageHistory of this PageTop of the SwikiRecent ChangesSearch the SwikiHelp Guide

Patch Launcher

This is a useful little patch for live performance. It basically sits on the top of the screen and lets you launch your patches.

Instructions:
var patchArray;
var window;

var top = 5, left = 25, rows = 0;

patchArray = [

["Clock", "/Applications/Supercollider/Casey/Clock/OscClock_01.rtf"],
["Looper", "/Applications/Supercollider/Casey/File Loopers/SingleSync3.rtf"],
["GenBeat", "/Applications/Supercollider/Casey/Generative Beats/generative_multiSample.rtf"],

];

patchArray.do({
	arg item, i;
	if((95 + left) > SCWindow.screenBounds.width, {
		top = top + 20;
		left = 25;
		rows = rows + 1;
	});
	left = left + 95;
});

top = 5;
left = 25;

window = SCWindow("Master", Rect(0, 721-(rows*20), SCWindow.screenBounds.width, 25+(rows*20)), 
	false, false
).front;

window.view.background_(Color(0.2, 0.2, 0.5));

SCButton(window, Rect(5, 5, 15, 15))
	.states_([["X"]])
	.action_({window.close});

patchArray.do({
	arg item, i;
	
	if((95 + left) > SCWindow.screenBounds.width, {
		top = top + 20;
		left = 25;
	});
	
	SCButton(window, Rect(left, top, 90, 15))
		.states_([[item.at(0)]])
		.action_({
			item.at(1).loadPath;
		});
		
	left = left + 95;
});
************
/*
authors so far:
casey basichis
*/


Link to this Page