You are not logged in.
I have two machines running archlinux. After upgrading arch on both, ffmpeg no longer would record audio from video streams. After googling the problem repeatedly, I finally ran across the solution: "Turns out I needed to install lib32-alsa-plugins". I'm not sure why it works, but audio is now recorded without any problems.
The website where I found the suggestion is: http://forums.unknownworlds.com/discuss … arch-linux (made by Forgotten_Path)
Here is my ffmpeg command:
ffmpeg -f alsa -ac 2 -i pulse -f x11grab -s 910x490 -i :0.0+0,300 -acodec pcm_s16le -vcodec libx264 -preset ultrafast -threads 0 -r 30 -y AlexanderDerGrosse.mkv Last edited by donatom (2014-02-24 16:33:02)
Offline
Please include the complete ffmpeg console output.
ffmpeg from the repository supports the PulseAudio input device, so you can try that instead of alsa:
ffmpeg -y -f pulse -ac 2 -i default -f x11grab -video_size 910x490 -framerate 30 -i :0.0+0,300 -acodec copy -vcodec libx264 -preset ultrafast -crf 0 AlexanderDerGrosse.mkvStuff 'n junk:
-y is a global option. Global options are placed before all other options.
Use -video_size instead of -s, and -framerate instead of -r as input options for x11grab.
Declare frame rate as an input option, otherwise ffmpeg will use the default input frame rate of 25 and then drop or duplicate frames to compensate (sometimes this is desired by the user).
You can probably stream copy the audio instead of re-encoding it, but it probably makes an insignificant difference.
I added -crf 0 to create a lossless output (this output can then be re-encoded after recording the screencast). You can remove it if performance using a lossless output is satisfactory.
Last edited by DrZaius (2014-02-24 07:04:30)
Offline
Thanks, DrZaius for your suggestions. I incorporated all of them in my command. I guess I didn't make it clear that after installing lib32-alsa-plugins from the arch repositories, ffmpeg is now recording the stream, audio included. If you have an idea why I needed lib32-alsa-plugins after a system upgrade, please let me know. Thanks again for your suggestions and explanation!
I would like to mark this as "solved", but don't know how.
Last edited by donatom (2014-02-24 16:31:33)
Offline
You can mark your thread as [Solved] by editing your first post and prepending it to the title.
Offline