Currently I am working on an app in which I wish to track someone in space using 2 cameras, that will have a 90 degree difference in viewing angle. I want to be able to pinpoint when two people are in touch, and when out of touch.
For this I wish to use two ps3 eye cams. I have previously set out to accomplish this, but n the end at that time did not need two cams (see: http://forum.openframeworks.cc/t/multiple-ps3eye-cams-on-windows-7-64bits/7790/0). I have now applied the change to ofGstVideoGrabber::get_device_data() suggested by Tim S.
At this point I see some problems, some unexplained behavior, and a little success:
Hardware: pc with intel quad core, Ubuntu 12.04 64 bits, usb ports at the back, 2 at the front and extra with a powered Sitecom hub.
Plugging two ps3 eye cams into the two ports in the front of the pc, I can run an app with the videoGrabbers, but it appears the load is too high on the USB: only one cam at a time gets updates, and then the other hangs a few frames (unusable).
Plugging two ps3 eye cams at different places in any combination except for the previously described: the application hangs at startup, then after some 15 seconds crashes with “Segmentation fault (core dumped)”.
Plugging one ps3 eye cam and a small Logitec webcam, it seems to only work fine when the ps3 eye is plugged into a usb port on the front of the pc, and the logitec is in the usb hub. However, this means at least one setting that actually works fine!
Note: using two instances of guvcview, I can view streaming video from two ps3 eye cams (both plugged into the front usb ports) at 30 fps at 640x480, or 125 fps at 320x240. Since there is limited control inside OF over video grabber settings, I do not know how to set grab framerate. Using "setDesiredFramerate(30) does not improve results.
Does anyone else have experience using multiple cams inside OF on Linux? And maybe experienced similar issues? I know the ps3 eye can be heavy on data traffic (potentially uses full usb2.0 bandwith), so it could be related to that, but the behavior I get is quite diverse and unpredictable. Maybe putting an extra pci-usb card in my pc could solve this? Or it could be something in the drivers behind it all (gstreamer)?
I would like to keep it inside Linux, since the SDK for ps3 multicam in Windows is closed source and nonfree. Also I don’t have the means to switch to firewire cams, I think.
If I find the time, I will do a similar test with ps3 eye cams using Pd/GEM to see if results are better or similar.
Thanks for any feedback.