i'm trying to write a shell script to analyse some videos by using the first frame of each second of video as a basis. i'm using ffmpeg to extract the frames. my script works ok if the video is progressive, but doesn't work so well for interleaved video (only the first field is output in that case, creating a half-height image). i've tried various combinations of deinterlacing (`yadif/bwdif`) with `select` but the filter chains i create either cause errors or still return a half-sized image. can someone help me with the syntax ?
here is my call w/a filter that works correctly for progressive video source :ffmpeg -i $infile -vf "select='if(eq(n\,0),1,floor(t)-floor(prev_selected_t))" -vsync 0 $outfilethe following still return only half-height images for interlaced source :... -vf "bwdif=0,select='if(eq(n\,0),1,floor(t)-floor(prev_selected_t))'"hope someone has some ideas.
... -vf "bwdif=0,select='between(mod(n\,$ips)\,1\,2)'" -- $ips is images per second
... -vf "select='between(mod(n\,$ips)\,1\,2)',bwdif=0"
+ Reply to Thread
Results 1 to 4 of 4
-vf bwdif=0 -r 1
Not testing your command lines since you didn't even bother to post the errors.users currently on my ignore list: deadrats, Stears555