Better way then clone() to get a single frame [closed]
Hi all, Noob question: I'm creating a history of faces, and currently the only way i found to do that is to create a face.clone() (other methods just make a copy of the video and then i have lots of little video's on the side, and i need a still frame) of the face it found. Is there a less cpu intensive way to do that (maybe like cap >> frame) ?
Thanks
seeing your code will be useful to understand your problem well.
It's just your average Facerecognizer code. After detectmultiscale and putting the face detected into Mat face, i do a : Vector<mat> facehistory; Mat tmp=face.clone(); facehistory[i].pushback(tmp) facehistory++;
And just go through the index later like so: for(i=facehistory-1;i>20;i--)
To show the last images.This works, but maybe this is the only way to do it ?