Where to find functional OpenCv Camera Calibration routine

I have the book ‘Learning OpenCV’ by Gary Braadski from O’Reilly. In the book they provide the code for a handy dandy little program that will calculate camera calibration metrics. The problem is that it is written for strict OpenCv and not Openframeworks with OpenCv. I tried adapting it, but the results just make the camera more distorted.

I also tried to install opencv by itself, but after an hour or two of trying to get everything to compiling I am giving up.

Is there a place to download a functioning program that will give the me camera calibration numbers (windows 7)? Alternatively, is there a place that has functional openframeworks code to do the same thing?

I found Stefanix’s version here: http://stefanix.net/ofcvcameracalibration. But it doesn’t compile (based on an old version of of, i suppose)

try ofxCv, it has an example to do camera calibration using the checkerboard:

http://github.com/kylemcdonald/ofxCv