erodeOut = hexagon.hvx.erode5x5(Input)
performs 2-D grayscale erosion of the input matrix Input with a 5-by-5
square structuring element for Hexagon® Vector eXtension (HVX).
%% Create a simple binary-style image (uint8)
H = 100; W = 128;
img = zeros(H, W, 'uint8');
% Draw two white squares
img(30:35, 30:35) = 255; % Square 1
img(60:65, 80:85) = 255; % Square 2
To apply erosion to the grayscale image with different kernel sizes, use the hexagon.hvx.erode3x3, hexagon.hvx.erode5x5, and hexagon.hvx.erode7x7 functions.
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window.
Web browsers do not support MATLAB commands.
Seleccione un país/idioma
Seleccione un país/idioma para obtener contenido traducido, si está disponible, y ver eventos y ofertas de productos y servicios locales. Según su ubicación geográfica, recomendamos que seleccione: .
También puede seleccionar uno de estos países/idiomas:
Cómo obtener el mejor rendimiento
Seleccione China (en idioma chino o inglés) para obtener el mejor rendimiento. Los sitios web de otros países no están optimizados para ser accedidos desde su ubicación geográfica.