How to know the detected face is of which frame in a matlab code of face detection and how to save first and last frame.
Mostrar comentarios más antiguos
videoFileReader = vision.VideoFileReader('h1.avi'); videoFrame = step(videoFileReader); figure, imshow(videoFrame) faceDetector = vision.CascadeObjectDetector; bbox = step(faceDetector, videoFrame); videoOut = insertObjectAnnotation(videoFrame,'rectangle',bbox,'Face'); figure, imshow(videoOut), title('Detected face')
Respuestas (1)
Dima Lisin
el 18 de Dic. de 2015
0 votos
Use an if statement to check if bbox is empty. If it is empty, then no face is detected. If not, then a face is detected.
Categorías
Más información sobre ROI-Based Processing en Centro de ayuda y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!