[FFmpeg-user] Input from Usb Microphone

info at picaflor-azul.com info at picaflor-azul.com
Sun Aug 5 17:33:19 CEST 2012


Hi,

    I am trying to get audio from a usb microphone, instead of the 
built-in microphone. The following commands will get the audio from the 
built-in microphone:


ffmpeg -f x11grab -r 30 -s 720x480 -i :0.0+10,100 -f alsa -ac 2 -i 
pulse -mbd 2 -trellis 2 -cmp 2 -subcmp 2 -g 100 -target ntsc-dvd -aspect 
16:9 out.vob
ffmpeg -f x11grab -r 30 -s 720x480 -i :0.0+10,100 -f alsa -ac 2 -i hw:0 
-mbd 2 -trellis 2 -cmp 2 -subcmp 2 -g 100 -target ntsc-dvd -aspect 16:9 
out.vob

Most of the other commands record nothing. (I think hw:0,0 records from 
the built-in microphone too.)

  more /proc/asound/devices
   1:        : sequencer
   2: [ 1- 0]: digital audio capture
   3: [ 1]   : control
   4: [ 0- 3]: digital audio playback
   5: [ 0- 0]: digital audio playback
   6: [ 0- 0]: digital audio capture
   7: [ 0- 3]: hardware dependent
   8: [ 0- 0]: hardware dependent
   9: [ 0]   : control
  33:        : timer


arecord -l
**** List of CAPTURE Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: STAC92xx Analog [STAC92xx 
Analog]
   Subdevices: 1/1
   Subdevice #0: subdevice #0
card 1: Device [USB PnP Audio Device], device 0: USB Audio [USB Audio]
   Subdevices: 1/1
   Subdevice #0: subdevice #0

  arecord -L
default
     Playback/recording through the PulseAudio sound server
sysdefault:CARD=PCH
     HDA Intel PCH, STAC92xx Analog
     Default Audio Device
front:CARD=PCH,DEV=0
     HDA Intel PCH, STAC92xx Analog
     Front speakers
surround40:CARD=PCH,DEV=0
     HDA Intel PCH, STAC92xx Analog
     4.0 Surround output to Front and Rear speakers
surround41:CARD=PCH,DEV=0
     HDA Intel PCH, STAC92xx Analog
     4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=PCH,DEV=0
     HDA Intel PCH, STAC92xx Analog
     5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=PCH,DEV=0
     HDA Intel PCH, STAC92xx Analog
     5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=PCH,DEV=0
     HDA Intel PCH, STAC92xx Analog
     7.1 Surround output to Front, Center, Side, Rear and Woofer 
speakers
dmix:CARD=PCH,DEV=0
     HDA Intel PCH, STAC92xx Analog
     Direct sample mixing device
dsnoop:CARD=PCH,DEV=0
     HDA Intel PCH, STAC92xx Analog
     Direct sample snooping device
hw:CARD=PCH,DEV=0
     HDA Intel PCH, STAC92xx Analog
     Direct hardware device without any conversions
plughw:CARD=PCH,DEV=0
     HDA Intel PCH, STAC92xx Analog
     Hardware device with all software conversions
sysdefault:CARD=Device
     USB PnP Audio Device, USB Audio
     Default Audio Device
front:CARD=Device,DEV=0
     USB PnP Audio Device, USB Audio
     Front speakers
surround40:CARD=Device,DEV=0
     USB PnP Audio Device, USB Audio
     4.0 Surround output to Front and Rear speakers
surround41:CARD=Device,DEV=0
     USB PnP Audio Device, USB Audio
     4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=Device,DEV=0
     USB PnP Audio Device, USB Audio
     5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=Device,DEV=0
     USB PnP Audio Device, USB Audio
     5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=Device,DEV=0
     USB PnP Audio Device, USB Audio
     7.1 Surround output to Front, Center, Side, Rear and Woofer 
speakers
iec958:CARD=Device,DEV=0
     USB PnP Audio Device, USB Audio
     IEC958 (S/PDIF) Digital Audio Output
dmix:CARD=Device,DEV=0
     USB PnP Audio Device, USB Audio
     Direct sample mixing device
dsnoop:CARD=Device,DEV=0
     USB PnP Audio Device, USB Audio
     Direct sample snooping device
hw:CARD=Device,DEV=0
     USB PnP Audio Device, USB Audio
     Direct hardware device without any conversions
plughw:CARD=Device,DEV=0
     USB PnP Audio Device, USB Audio
     Hardware device with all software conversions

ffmpeg -version
ffmpeg version 0.10.4-6:0.10.4-0ubuntu0jon2
built on Jun 12 2012 23:02:05 with gcc 4.6.3
configuration: --extra-version='6:0.10.4-0ubuntu0jon2' --arch=amd64 
--prefix=/usr --libdir=/usr/lib/x86_64-linux-gnu --disable-stripping 
--enable-vaapi --enable-vdpau --enable-bzlib --enable-gnutls 
--enable-libgsm --enable-libschroedinger --enable-libspeex 
--enable-libtheora --enable-libvorbis --enable-pthreads --enable-zlib 
--enable-libvpx --enable-runtime-cpudetect --enable-libfreetype 
--enable-libpulse --enable-vaapi --enable-librtmp --enable-gpl 
--enable-postproc --enable-x11grab --enable-libcdio --enable-version3 
--enable-libdc1394 --shlibdir=/usr/lib/x86_64-linux-gnu --enable-shared 
--disable-static
libavutil      51. 35.100 / 51. 35.100
libavcodec     53. 61.100 / 53. 61.100
libavformat    53. 32.100 / 53. 32.100
libavdevice    53.  4.100 / 53.  4.100
libavfilter     2. 61.100 /  2. 61.100
libswscale      2.  1.100 /  2.  1.100
libswresample   0.  6.100 /  0.  6.100
libpostproc    52.  0.100 / 52.  0.100


Thanks,

Anne


More information about the ffmpeg-user mailing list