-1
FDetect = vision.CascadeObjectDetector;
%// Read the input image
I = imread('face.jpg');
%// Returns Bounding Box values based on number of objects
BB = step(FDetect,I);
figure,
imshow(I);
hold on
for i = 1:size(BB,1)
rectangle('Position',BB(i,:),'LineWidth',2.5,'LineStyle','','EdgeColor','r');
end
title('Face Detection');
hold off;
フィルタを与える:顔検出およびフィルタに
E = imerode(I,strel('square',5));
figure, imshow(E);
私の問題は、長方形の顔領域でフィルタを与える方法です。