问题
I have a problem using ffmpeg: when i trying to record video+audio from my webcam in result i got only video stream, wthout audio at all. I have tried different codecs and nothing.. Maybe, someone can give me advice?
ffmpeg -f dshow -i video="Logitech HD Webcam C270" -r 25 -s 800x600 -acodec libmp3lame -vcodec mpeg4 -b 3000k -f avi D:\1.avi
Btw: virtualdub grabs both well. Thanks.
回答1:
Assuming that you have installed the driver and codecs, use something like:
ffmpeg -f dshow -i video="Logitech HD Webcam C270" [path]out.mp4
A short explanation is given in capture a webcam input. For using DirectShow you have this examples.
来源:https://stackoverflow.com/questions/14487393/how-to-record-audio-stream-using-ffmpeg