imextendedmax
Find extended maxima in a 2-D image.
📝Syntax
BW = imextendedmax(I, h)
BW = imextendedmax(I, h, conn)
📥Input Arguments
Parameter Description
I Input finite real 2-D image.
h Nonnegative finite height for the h-maxima transform.
conn Connectivity, either 4, 8, or an equivalent 3-by-3 matrix.
📤Output Arguments
Parameter Description
BW Logical mask of regional maxima after h-maxima suppression.
📄Description

imextendedmax applies imhmax and then finds regional maxima. It helps build marker masks that ignore maxima shallower than h.

💡Examples
Find extended maxima
I=[1 1 1 1 1;1 5 1 4 1;1 1 1 1 1];
BW=imextendedmax(I,2);
figure; subplot(1,2,1); imagesc(I); title('Image');
subplot(1,2,2); imagesc(BW); title('Extended maxima');
Example illustration
🔗See Also
imhmaximregionalmaximextendedmin
🕔Version History
Version Description
2.0.0 initial version
Edit this page on GitHub