Ask Your Question
1

frameskipping

asked 2016-09-20 16:40:16 -0600

atv gravatar image

I wanted to use something like

for(;;) {

cap << frame; if (frameno % 3 == 0) frameNo++; { Do all our stuff } imshow

Depending how high i set my frames to be skipped the face rectangle just flickers more. This is of course expected, but not desired. I just want it to process less frames (it would still get all of them of course) but have no impact on my display.

What am i missing?

edit retag flag offensive close merge delete

Comments

I would do

Rect faceRect;
for(;;) {
    cap << frame; 
    if (frameno % 3 == 0) frameNo++; {
        Do all your stuff
        set the faceRect 
    }
    rectangle(frame,faceRect, ...)
    imshow
pklab gravatar imagepklab ( 2016-09-21 12:22:38 -0600 )edit

That makes sense! So this would still include the actual face detection correct, just not the face recognition processing.

Thanks a lot

atv gravatar imageatv ( 2016-09-21 12:44:38 -0600 )edit

I don't understand your comment but to avoid flickering you have to draw the rectangle each frame you show. Where the rectangle is placed when you skip the frame is it's up do you.

pklab gravatar imagepklab ( 2016-09-21 12:55:08 -0600 )edit

You need to apply a tracker on top of your detections that smooth your detections over time. The jitter is normal due to the pixel difference in found detection regions!

StevenPuttemans gravatar imageStevenPuttemans ( 2016-09-22 06:37:49 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
1

answered 2016-09-22 09:52:26 -0600

atv gravatar image

Thanks all

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2016-09-20 16:40:16 -0600

Seen: 339 times

Last updated: Sep 20 '16