Every time I try to compile my code to check grayscale, I put in the input they gave in the instructions:
./filter -g infile.bmp outfile.bmp
But I keep getting this message saying Could not open infile.bmp.
How do I compile this to check it?
Every time I try to compile my code to check grayscale, I put in the input they gave in the instructions:
./filter -g infile.bmp outfile.bmp
But I keep getting this message saying Could not open infile.bmp.
How do I compile this to check it?
That's simple because infile.bmp does not exist, that is just a placeholder it means that, that the path you put in there should contain a file. The folder images has images where you could process or filter. Try doing ./filter -g images/tower.bmp images/greytower.bmp. This basically means ./filter will run your program, -g will state that you want to use the grayscale function, images/tower.bmp is the path where the file you want to filter will be, then images/greytower.bmp is the path and the filename you want to place the filtered image. if you run that you should see in your images folder a file called greytower.bmp, and if your code is correct then if you view the image it should be grayscaled.