how to crop face from many number of frames(video)?I just croped 3 faces from single frame.Here is my code.Also show me how to save cropped faces from each frame in array?
1 次查看(过去 30 天)
显示 更早的评论
clc; clear all; obj=VideoReader('vtu.avi');
img = read(obj,1); figure(1),imshow(img);
FaceDetect = vision.CascadeObjectDetector;
BB = step(FaceDetect,img);
figure(2),imshow(img);
end
for i = 1:size(BB,1)
rectangle('Position',BB(i,:),'LineWidth',3,'LineStyle','-','EdgeColor','r');
end for i = 1:size(BB,1) J= imcrop(img,BB(i,:)); figure(3),subplot(2,2,i);imshow(J); end
0 个评论
回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!