openframeworks/openFrameworks — pull request #2402 by arturoc (2013-08-02 15:54:09+00:00)
Title: ofxKinect: triple buffering, avoids 4 copies per frame

right now ofxKinect is doing a copy of the video and depth buffers on the kinect thread and another in the gl thread and locking in both.

This implements triple buffering avoiding every copy so interlocking should be almost inexistent. In a cpu intensive application that i'm developing before this change i was getting 20fps on both video and depth streams with this i get 30fps without problem

It will probably help with the issues in osx since the current method is locking the kinect thread a more time that it should possibly breaking the usb comunication but haven't tried.