|
1 |
| -#include <string> |
2 |
| -#include <iostream> |
3 |
| -#include <iomanip> |
4 |
| -#include <vector> |
5 |
| - |
6 |
| -#include "opencv2/opencv.hpp" |
7 | 1 | #include "opencv2/core.hpp"
|
8 | 2 | #include "opencv2/highgui.hpp"
|
9 | 3 | #include "opencv2/photometric_calib.hpp"
|
10 |
| -#include "opencv2/imgproc/imgproc.hpp" |
11 | 4 |
|
12 | 5 | using namespace std;
|
13 | 6 | using namespace cv;
|
@@ -48,13 +41,13 @@ int main(int argc, char** argv)
|
48 | 41 | // The result and some intermediate data are stored in the folder ./vignetteCalibResult in which
|
49 | 42 | // vignette.png and vignetteSmoothed.png are the vignette images.
|
50 | 43 | // In practice, vignetteSomoothed.png is used, since it doesn't have the black boarders.
|
51 |
| - Mat vigSmoothed = imread("./vignetteCalibResult/vignetteSmoothed.png", CV_LOAD_IMAGE_UNCHANGED); |
| 44 | + Mat vigSmoothed = imread("./vignetteCalibResult/vignetteSmoothed.png", IMREAD_UNCHANGED); |
52 | 45 | // As shown as Fig.4 in the paper from J.Engel, et al. in the paper A Photometrically Calibrated Benchmark For Monocular Visual Odometry
|
53 | 46 | namedWindow( "Vignette Smoothed", WINDOW_AUTOSIZE );
|
54 | 47 | imshow("Vignette Smoothed", vigSmoothed);
|
55 | 48 |
|
56 | 49 | // To see the vignette-calibrated image, we can use VignetteRemover
|
57 |
| - Mat oriImg = imread(imageFolderPath + "/00480.jpg", CV_LOAD_IMAGE_UNCHANGED); |
| 50 | + Mat oriImg = imread(imageFolderPath + "/00480.jpg", IMREAD_UNCHANGED); |
58 | 51 | photometric_calib::GammaRemover gammaRemover(gammaPath, oriImg.cols, oriImg.rows);
|
59 | 52 | photometric_calib::VignetteRemover vignetteRemover("./vignetteCalibResult/vignetteSmoothed.png", gammaPath, oriImg.cols, oriImg.rows);
|
60 | 53 | Mat resCaliImg = gammaRemover.getUnGammaImageMat(oriImg);
|
|
0 commit comments