1
0
mirror of https://github.com/2martens/uni.git synced 2026-05-06 19:36:26 +02:00
Files
uni/ccv/sheet4/main.cpp
Jim Martens 47883edea3 [CCV] Modified LAB pyramid to work with given image
Signed-off-by: Jim Martens <github@2martens>
2017-05-02 15:11:23 +02:00

30 lines
590 B
C++

#include <iostream>
#include <opencv2/opencv.hpp>
#include "lab_pyramid.h"
int main(int argc, char** argv) {
if ( argc != 2 )
{
printf("usage: <Image_Path>\n");
return -1;
}
cv::Mat image;
image = cv::imread(argv[1], cv::ImreadModes::IMREAD_COLOR);
int layers = 4;
float sigma_center = 3;
float sigma_surround = 5;
// center
lab_pyramid pyr_center = lab_pyramid(image);
pyr_center.create_pyramids(sigma_center, layers);
// surround
lab_pyramid pyr_surround = lab_pyramid(image);
pyr_surround.create_pyramids(sigma_surround, layers);
return 0;
}