The example projects provided with the camera's drivers and API library showed how to do all sorts of fancy stuff – but not one of them would focus on the basics of grabbing a pair of left-and-right images and writing them to disk. Of course, I was able eventually to see through all the extras and gather just enough code to do what I wanted; but that didn't change the fact that PointGrey's example set was flawed – that it should show how to do the basic stuff before illustrating the more advanced features.
This archive is my attempt to mend that flaw, should anyone ever need a basic example on grabbing photos from a Bumblebee2 camera – or any other camera acessible through the FlyCapture API. It contains the source code and makefile for a small application called BeeCap, which illustrates how to:
- Stablish an interface to the camera;
- For the Bumblebee2, select the left or right camera;
- Load a photo to a memory buffer;
- Write the contents of the buffer to a file.
The application has a known issue concerning the Bumblebee2: you cannot grab a stereo pair of buffers and then write them both to disk – if you do, you end up with two copies of the same photo, taken from the last selected camera. Saving the firt buffer before grabbing the next solved the issue, and I was short on time back when I was working on the camera interface, so I never really discovered what was going on; take figuring it out as an exercise if you like – and contact me if you do. ;)