DIFFERENCE_FILTER_CVIP

difference_filter_cvip() - performs convolution between an image I and a mask M..

Contents

SYNTAX

difference = difference_filter_cvip(I,M)

Input Parameters include :

Output Parameter include:

DESCRIPTION

The Difference filters are linear enhancement filters which enhance the details in an image. They are linear as they can be implemented with convolution masks. Difference filters enhance the image details in a specific direction depending on the coefficients of the convolution mask selected. The function implements difference filter on the input image by convolving the image with a mask type specicfed by the user.

REFERENCE

1. Scott E Umbaugh. DIGITAL IMAGE PROCESSING AND ANALYSIS: Applications with MATLAB and CVIPtools, 3rd Edition.

EXAMPLE

Read image

 input_image1 = imread('cam.bmp');
 input_image2 = imread('butterfly.tif');

% Mask type

 mask_type1 = 3;
 mask_type2 = 5;

% Call function

 difference1 = difference_filter_cvip(input_image1 ,mask_type1);
 difference2 = difference_filter_cvip(input_image2 ,mask_type2);

% Display input image

 figure;imshow( input_image1 );title('Input Image1');
 figure;imshow( input_image2 );title('Input Image2');

% Display output image

 figure; imshow(hist_stretch_cvip(difference1,0,1,0,0));title('Output Image1');
 figure; imshow(hist_stretch_cvip(difference2,0,1,0,0));title('Output Image2');

CREDITS

Author: Lakshmi Gorantla, July 2017
Copyright © 2017-2018 Scott E Umbaugh
For updates visit CVIP Toolbox Website