Homomorphic Filtering

When the image formation process is viewed as a product of image illumination and scene reflectance, it is natural to remove the low frequency variations due to illumination by taking the log of the image before high pass filtering and then the exp to display the result. This is exactly what homomorphic filtering does to enhance details in an image. The butter -H program uses a butterworth filter together with log/exp to perform homomorphic filtering. The cut off frequency and filter shape are specified by program switches. (see code)

Command Usage

butter [options] infile outfile
       [-l]    Lowpass filtering
       [-h]    Highpass filtering
       [-L]    Homomorphic lowpass filtering
       [-H]    Homomorphic highpass filtering
       [-f #]  Frequency with filter = 1/2
       [-n #]  Denominator exponent
       [-b #]  Filter boost (Homomorphic only)

Example

butter -H -f 20 input.im homomo.im
disp input.im homomo.im