[FFmpeg-user] Audio cut when using select filter

Martin Ždila m.zdila at gmail.com
Tue Jan 17 18:15:47 EET 2017


I am trying to grab a screen with audio, record it to mp4 file and also
extract 60th frame as jpeg:

ffmpeg -hide_banner -y -thread_queue_size 512 -video_size 800x600
-framerate 30 -r 30 -f x11grab -draw_mouse 0 -i :0.0 -thread_queue_size 512
-f pulse -i default -filter_complex
"[0:v]split=2[in1][in2];[in2]copy[out2];[in1]select=eq(n\,60)[out1]" -map
'[out2]' -map '1:a' -vcodec libx264 -acodec libmp3lame -preset fast xxx.mp4
-map '[out1]' -frames:v 1 xxx.jpeg

The problem is that after the frame for jpeg is selected the audio is no
more recorded. How could I solve it?

Thanks in advance
Martin Ždila

More information about the ffmpeg-user mailing list