| Image Processing Toolbox | ![]() |
Syntax
Description
IM2 = imbothat(IM,SE) performs morphological bottom-hat filtering on the grayscale or binary input image, IM, returning the filtered image, IM2. The argument SE is a structuring element returned by the strel function. SE must be a single structuring element object, not an array containing multiple structuring element objects.
IM2 = imbothat(IM,NHOOD) performs morphological bottom hat filtering where NHOOD is an array of 0's and 1's that specifies the size and shape of the structuring element. This is equivalent to imbothat(IM,strel(NHOOD)).
Class Support
IM can be numeric or logical and must be nonsparse. The output image has the same class as the input image. If the input is binary (logical), then the structuring element must be flat.
Example
Top-hat filtering and bottom-hat filtering can be used together to enhance contrast in an image.
I to the top-hat filtered image, and then subtract the bottom-hat filtered image.
See Also
| imapprox | imclearborder | ![]() |
Learn more about the latest releases of MathWorks products: |
| © 1994-2009 The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |