Unsharp Masking

There are a number of linear methods for enhancing the details in images. One common method is unsharp masking, where a blurred version of an image is subtracted from the original to emphasize fine details. In our unsharp program, we use multiple iterations of binomial smoothing to smooth the image and subtract a specified fraction of the smooth image from the original. The number of iterations and subtraction fraction are specified by command line switches. (see code)

Command Usage

unsharp [options] infile outfile
        [-d]      Print debugging information
        [-k # #]  Number of smoothing iterations (default 1 5)
        [-f #]    Fraction of smooth image to subtract (default 0.8)

Example

unsharp -k 1 8 input.im unsharp.im
disp input.im unsharp.im