Codeshare: Kinect2 RGB through Processing3 to TouchDesigner (via Syphon)... in OS X 10.15.7


I wanted to share a simple kludge, in case it helps anyone.

Let’s assume you’ve got Processing v3.5.4 installed on your OS X 10.15.7 machine.

And further assume that… within Processing, you have OpenKinect and Syphon happily installed.

If so, this snippet might be useful:

/* import dependencies */
import codeanticode.syphon.*;
import org.openkinect.processing.*;

/* remap some names */
Kinect2 kinect2;
SyphonServer server;

/* define square Processing raster--change 1024,1024 to fit your needs */
void settings(){

/* our syphon texture will be called "Kinect Processing" */
void setup(){
  kinect2 = new Kinect2(this);
  server = new SyphonServer(this, "Kinect Processing");

/* shift kinect output over by -500px within the 1024x1024 canvas */
void draw(){
  image(kinect2.getVideoImage(), -500, 0);

On the TD side:

Drop down a Syphon Spout In TOP… select “Kinect Processing” as the source… and voilà!

Of course… this is the tip of the iceberg… but for my purposes today… this was just the ticket.

Happy Touch-ing,

1 Like