[SOLVED] Download helper screen capture with ffmpeg?
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
The sort of add on for Firefox 'download helper' now has a new screen capture thing, in case it won't download the video from a particular site. You click the red button and a purple boundary appears round the video frame. I assume this is the basic function of the thing; it then provides the geometry of the purple frame to the program you've given it to capture the video.
By default the program it uses is 'recordmydesktop'. I've tried using this but get sound from the laptop's internal microphone, not the video. Tried 'pavucontrol' to remedy this but it says (wrongly) that no program is recording, so can't put things right.
Assume the stuff in curly brackets is what download helper supplies. Sometimes works perfectly but with B.BC. i-player only get the top left hand corner of the video and it is stretched somewhat horizontally.
#! /bin/bash
# Filename downloadHelperBbcIplayer.sh
# Try to get the Firefox thing DownloadHelper to work better for i-player.
/usr/local/bin/ffmpeg `echo "-f alsa -ac 2 -f pulse -f x11grab -s cif -y -b 128k -r 25 -i :0.0+"$1","$2" -s "$3"x"$4" "$5`
#exit (0)
This stops the red button working for democracynow.org a thing it used to work perfectly before. But i-player works just as before, as you would expect, *except there is no sound*.
I do not have a computing degree like many of the people on the internet and this sort of thing completely mystifies me. There is no reason to it and you come up against this sort of thing again and again.
What I mean is democracynow.org should work the same as before, i.e. correctly, because apparently nothing has changed. Ditto i-player - which is now sans sound.
(For completeness it has to be stopped manually by terminating ffmpeg.)
Last edited by lugoteehalt; 07-03-2011 at 08:33 PM.
Q: How can I control PulseAudio input? (e.g. capture application audio instead of mic)
A: Install “pavucontrol“. Start recording with ffmpeg. Start pavucontrol. Go to the “Recording” tab and you’ll find ffmpeg listed there. Change audio capture from “Internal Audio Analog Stereo” to “Monitor of Internal Audio Analog Stereo“.
Now it should record system and application audio instead of microphone.
This setting will be remembered. The next time you want to capture with FFmpeg, it will automatically start recording system audio. If you want to revert this, use pavucontrol again to change back to microphone input.
Bit embarassing. Just had made some elementary errors in ffmpeg flags, i.e. should be -i pulse not -f pulse and -s cif is what was telling it to get the wrong area to capture, it should be ommited.
Fixing that makes it work. But it has poorish image quality. Got some sort of bug with ffmpeg, or compiled it wrongly, so difficult to sort this out. But the principle of it works anyway.
It gives a fair image quality, i.e. fiddling about will give something usefull.
The point is it is very point and click friendly: You just connect to the video on firefox, hover the pointer over the red button, and click and the thing gets recorded. Otherwise you have to put the coordinates of the video's frame in manualy, which certainly defeats me.
EDIT: ffmpeg has to be compiled by yourself to include X11grab, etc. As in the link above.
Last edited by lugoteehalt; 07-13-2011 at 05:22 PM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.