This is documentation for Mathematica 7, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.1)

ImageFilter

ImageFilter[f, image, r]
applies the function f to the range r neighborhood of each pixel in each channel of image.
  • ImageFilter[f, image, r] replaces the value of each pixel by the result of applying the function f to the (2 r+1)×(2 r+1) array of values around that pixel.
  • ImageFilter operates separately on each channel in an image.
  • ImageFilter[f, image, {rrow, rcol}] uses range rrow in the row direction, and rcol in the column direction.
  • ImageFilter[f, image, {{rtop, rbottom}, {rleft, rright}}] picks out neighborhoods that extend rtop rows up, rbottom rows down, rleft columns to the left, and rright columns to the right.
  • The channel values supplied to f are normally in the range 0 to 1, regardless of the underlying type used in the Image object. The function f is assumed to return channel values that are normally in the range 0 to 1.
  • The following options can be given:
Padding"Fixed"what values to assume beyond the image
InterleavingFalsewhether to supply f lists of channel values
  • With the default setting Interleaving->False, the elements in the arrays to which f is applied are individual channel values for pixel.
  • With Interleaving->True, the elements are instead the list of all channel values for a particular pixel.
Apply a local minimum filter:
Blur an image by replacing each pixel with the local mean:
Apply a local minimum filter:
In[1]:=
Click for copyable input
Out[1]=
 
Blur an image by replacing each pixel with the local mean:
In[1]:=
Click for copyable input
Out[1]=
Mean filter computed over all channels:
Find the exact position of an image fragment:
Median deviation filter:
New in 7