1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
|
#include "Bitmap.h"
#include "Bitmap.h" //test protection against double include
#include <string>
#include <iostream>
using namespace std;
int main(int argc, char* argv[])
{
const char* fnames[]={"hoohah","atc203.bmp","atc204.bmp","bluesky.bmp",
"flower1.bmp","flower2.bmp","ice.bmp","moon.bmp","yellowflower.bmp",
""};
int collars[]={123,16,8,32,12,24,4,3,12};
for(int i=0;fnames[i][0];++i){
Bitmap b1(fnames[i]);
b1.quantize(collars[i]);
b1.save(string("quantification-")+fnames[i]);
}
return 0;
}
|