Convolution Filter Visualized

Convolution Filter Visualized

The center of the mask is placed over the pixel you are manipulating in the image.
And the I & J values are used to move the file pointer so you can mulitply, for example, pixel (a22) by the corresponding mask value (m22).

It is important to notice that pixels in the first and last rows, as well as the first and last columns cannot be manipulated by a 3x3 mask. This is because when placing the center of the mask over a pixel in the first row (for example), the mask will be outside the image boundaries.
Source of information:

Convolution Filter Visualized for HW4-3-5 (edge detection)

Visualization of a basic convolution filter algorithm:

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License