Files
small-image-descriptors/main.cpp
T
2019-06-29 15:14:12 +02:00

35 lines
865 B
C++

/*#include <Magick++.h>
#include <iostream>
#include <bitset>
#include <climits>
#include <boost/filesystem/fstream.hpp>
#include <string>*/
#include "DescriptorManager.h"
#include <boost/filesystem.hpp>
#include <Magick++.h>
using namespace std;
using namespace Magick;
enum method {avg_color, num_color, median, sobel, pearson, threshold, dct_pearson, dct_median};
int main(int argc, char **argv) {
string imagename = "im3102.jpg";
int method = method::median;
if (argc > 2) {
method = atoi(argv[2]);
imagename = argv[1];
}
else {
cout << "Usage: " << endl << argv[0] << " [fileName] [methodIndex]" << endl;
cout << "Continuing.." << endl;
}
InitializeMagick(*argv);
DescriptorManager* manager = new DescriptorManager("test");
manager->Init();
manager->rankImages(imagename, method);
manager->outputRank(imagename, method);
return 0;
}