Some words about my Google Summer of Code project.

June 1st, 2008 by nictuku

In this post I'm going to talk a bit about what I'm doing at my GSoC project.
Basically it consists of 2 main goals:

  1. Implement MIDI in the Network Editor (NE from here)
  2. Implement Typed Controls.

Since the Typed Controls implementation is necessary for the MIDI stuff I'm giving it some priority.
I'm going to avoid all the CLAM background because it's well explained in the project's page and its tutorials.
CLAM uses Controls to modify Processing's internal parameters.
The basic problem with Controls is that at this moment they only manage float as data type, this hardly limits what you can do with them,
The idea of my project is to extend this functionality to have the possibility to use any data type that the programmer wishes. (float, integers, MIDI, OSC ;) )
For this i'm using the loved (and hated by many) C++ Templates.
Basically i wrote two classes called TypedInControl and TypedOutControl, which will replace InControl and OutControl in the future, but, to avoid compatibility issues, we decided not to touch the existent classes.
I'm using a design pattern for typed data connection that is already implemented in CLAM with the Ports (which are typed streams like audio, etc.). The data pattern has as main goal to let a non typed connector to generate typed connections correctly and with type check. To achieve this we divide the tasks in two clases, a base class (non-typed) and a child typed class, the type cheching is delegated to the child class, while the actual connection is being made with the base class.
At the moment all this is already implemented and working well.
Now I'm in charge of a more advanced step, the control registry for the processings. I'll write about this soon.

Talking about the MIDI implementation, the mail idea is to create 2 basic processings: MIDISource and MIDISink. MIDISource will be the one in charge of getting external MIDI messages and letting them flow in the CLAM network. Inversely, MIDISing will send MIDI messages generated (or modified) in CLAM to the external world. Both are going to use the Typed Controls, instantiated with MIDI messages as data type.
Besides these basic processings I've planned to create some processings that use them to have usefull functionality for musicians. For example, I'm already working on a MIDINote to Frequency and Amplitude translator called MIDINoteOutControlSender (I'll talk about this soon). At the beginning of the project I coded the MIDIMon, which basically reads MIDI messages and translates them into floats to see that MIDI is working.
I'm planning to code the MIDIControlSender, which will be in charge to read the MIDI control messages and translate them into floats to control parameters of existing processings.
Also I've a MIDIArp in mind, it's a MIDI arpeggiator (very useful to be used in MIDI controlled synths) and some other things i think will be interesting (maybe delays and that kind of stuff).

Bookmark and Share:

Leave a Reply