Hi, everyone! I’m not exactly sure where this question should go, so I’m going to post it here until someone points me in the right direction?
I’m trying to use the ofxVideoGrabberPtgrey extension (found at https://code.google.com/p/ofxvideograbberptgrey/) to get my Point Grey camera to work with OpenFrameworks 0072 on Windows 7. I’m using Code::Blocks 10.05, not that that should make a difference. Anyway, I’ve got the linking working, but I guess the ofxVideoGrabberPtgrey extension is fairly old, and it doesn’t seem to implement the right things for the new version of OpenFrameworks. Below is what I see when I try to compile code (all I’ve done is take the example videograbber code and replace the videograbber with a videograbberptgrey):
Compiling: src\main.cpp
In file included from C:\Users\Valkyrie\projects\libraries\openframeworks\examples\video\videoGrabberExample\src\main.cpp:2:
C:\Users\Valkyrie\projects\libraries\openframeworks\examples\video\videoGrabberExample\src\testApp.h:22:
error: cannot declare field 'testApp::vidGrabber' to be of abstract type 'ofxVideoGrabberPtgrey' ..\..\..\addons\ofxVideoGrabberPtgrey\src/ofxVideoGrabberFlyCapture.h:15:
note: because the following virtual functions are pure within 'ofxVideoGrabberPtgrey': ..\..\..\libs\openFrameworks\types/ofBaseTypes.h:99:
note: ofPixels_<PixelType>& ofBaseHasPixels_<T>::getPixelsRef() [with T = unsigned char]
Has anyone had success with this library? I am pretty new to C++ and brand new to OpenFrameworks. I didn’t really find any resolutions to questions about using Point Grey cameras with the new versions of Windows, Code::Blocks, or OpenFrameworks (all the results I’m finding where people had success with the Point Grey cameras in the OFX fora are from ~3 years ago). Any pushes in the right direction would be helpful.
I ran into this same error on Linux and was able to work around it. This was with a recent GigaE Blackfly. Hopefully when I get a moment I can document how. But in case I forget the steps involved…
Changing the ofxVideoGrabberPtgrey. to default to the FlyCapture header rather than the dc1394.
moving entirely from the example codeblocks project into a project I created from scratch using the OF ‘projectGenerator’.
Creating a addon_config.mk for the ofxVideoGrabberPtygrey addon and setting it so that it ignores the libs/FlyCapture directory it came with and instead loads the includes from /usr/lib/flycapture (the pointgrey installed sdk location).
Modify ofxVideoGrabberFlyCapture.cpp/.h to reference getPixelsRef. This is the reason for the error you ran into.
Modified ofxVideoGrabberFlyCapture.cpp and commented out all of the camera settings changes (leaving with the standard defaults).
(items I’m not certain were essential have * at end)
brew install libdc1394
add /usr/local/include to xcode headers search path *
add addons/ofxVideoGrabberPtgrey sources to xcode items. Be sure to add ofxVideoGrabberDc1394.cpp to projects target build phase so it is compiled on build
add the lib/osx/libdc1394.a found in the addons lib dir to the project target build phase
modify the ofxVideoGrabberDc1394.cpp/.h to include
the getPixelsRef() stub as shown above for the Linux instructions
Currently this compiles and shows a frame but it is unable to detect the GigE camera. If has a solution for getting libdc1394 to work with GigE cameras please point me in the right direction. The Pointgrey site indicates libdc1394 supports GigE but some mailinglist posts on the dc1394 mailinglist differ