//**************************************************************************
//
//      CSE 585 Project #1
//      By Anirudh Modi (anirudh@bart.aero.psu.edu) on 3/10/2000-Fri
//       & Shin Chin (scc136@psu.edu)
//       & Ming Ni (ni@cse.psu.edu)
//
//**************************************************************************
//      Running time of algorithm -> O[width x height]
//**************************************************************************
//      Have implemented the following ->
//              1. Smoothening of histogram to determine minima/maxima
//              2. Basic image operations (+, -, =)
//              3. There is no memory leak
//**************************************************************************
#include <iostream.h>
#include <fstream.h>
#include <stdio.h>
#include <stdlib.h>     // for atoi()
#include <string.h>
#include <math.h>
#include "image.h"
#include "matrix.h"
#include "gabor.h"
//**************************************************************************
int main (int argc, char *argv[])
{
GrayImage image, rI, gI, bI;

if (argc < 2)
        {
         cerr << "Syntax: " << argv[0] << " <pbm-color-image-file>" << endl;
         exit(-1);
        }
image.ReadRGBimageFromFile(argv[1], &rI, &gI, &bI);     // Read the image file

rI.WriteToFile("R.dat");
gI.WriteToFile("G.dat");
bI.WriteToFile("B.dat");
image.WriteToFile("gray.dat");
}
//**************************************************************************