Copyright Razvan-Constantin Rus 312CAa 2022-2023
This program is a CLI image editor for PGM and PPM files. It can rotate, crop, equalize, apply filters, print a histogram and save the results in either ascii or binary format.
-
LOAD <filename>- deletes the previously loaded picture and loads a new one from<filename>. -
SELECT <x1> <x2> <y1> <y2>- selects a portion of the picture loaded. -
SELECT ALL- selects the whole picture loaded. -
EQUALIZE- if the loaded picture is a grayscale one, it equalizes the picture. -
CROP- crops the picture, keeping the selected area -
APPLY <FILTER>- applies one of the 4 filters: EDGE, SHARPEN, BLUR, GAUSSIAN BLUR. -
HISTOGRAM <x> <y>- prints a histogram of the picture loaded, provided that it is a grayscale one. The histogram is made ofybins, whilexis the max value of a bin. -
ROTATE <angle>- Only works if the angle is a multiple of 90. -
SAVE <filename> [ascii]- saves the loaded picture into . Theasciiparameter is optional, saving the picture in ASCII format. Otherwise, the picture is saved in binary format.