GML



Extra libraries for Pure Data , a graphical multi-media programming environment.
Linux wrappers around csound, a text based sound programming language.
They are GPL, the ff and jackx externals are linux only.

ff externals allow you to control forcefeedback effects on common iforce gaming controllers from within pd.

Jackx externals allow you to query and control jack connections from within a pd patch

Beatpipe is an event driven scheduler/quantizer, that will schedule lists of any length. Timing is set in terms of beats, and the tempo and the quantification can be changed on the fly. It should compile on any system that can run PD, but I only supply a linux makefile

Csound-wrappers is my project on sourceforge, it consists at the moment of jcsound, a jack and alsa-sequencer capable csound

The externals are also available at pure-data.sourceforge.net-> in the CVS repository.
 
some code that is a background image in image-capable browsers, ignore if you are using lynx etc.
void ff_bang(t_ff *x)
{
	if (x->ff_fd < 0) return;
	if (x->effects.id == -1) {
		post("effect is not loaded, use a \"load\" message to upload to device");
		return;
	}

	x->do_that.type = EV_FF;
	x->do_that.code = x->effects.id;
	x->do_that.value = 1;

	if (write(x->ff_fd, (const void*) &x->do_that, sizeof(x->do_that)) == -1) {
		perror("Play effect error");
	}
	outlet_float(x->x_obj.ob_outlet, (t_float) x->effects.id);
}

void ff_stop(t_ff *x)
{

	if (x->ff_fd < 0) return;
	if (x->effects.id == -1) {
		post("effect is not loaded, use a \"load\" message to upload to device");
		return;
	}

	/* is it still playing ? */

	x->do_that.type = EV_FF_STATUS;
	x->do_that.code = x->effects.id;

	if ((read(x->ff_fd, (void *) &x->do_that, sizeof(x->do_that)))  == -1) {
		perror("couldn't read status of effect");
	}

	if (x->do_that.value = FF_STATUS_PLAYING) {

		x->do_that.type = EV_FF;
		x->do_that.code = x->effects.id;
		x->do_that.value = 0;
		
		if ((write(x->ff_fd, (const void*) &x->do_that, sizeof(x->do_that))) == -1) {
			perror("Stop effect error");
		}
	}
}

void ff_delay(t_ff *x, t_floatarg delay)
{
	if (x->ff_fd < 0) return;