[FFmpeg-trac] #449(undetermined:new): ALSA, as a first input, together with -isync gives error "[alsa @ 0x97ddae0] cannot set parameters (Connection timed out)"

FFmpeg trac at avcodec.org
Sat Sep 10 07:40:41 CEST 2011


#449: ALSA, as a first input, together with -isync gives error "[alsa @
0x97ddae0] cannot set parameters (Connection timed out)"
-------------------------------------+-------------------------------------
             Reporter:  burek        |                     Type:  defect
               Status:  new          |                 Priority:  normal
            Component:               |                  Version:
  undetermined                       |  unspecified
             Keywords:               |               Blocked By:
             Blocking:               |  Reproduced by developer:  0
Analyzed by developer:  0            |
-------------------------------------+-------------------------------------
 This works:

 {{{
 # ffmpeg -isync -f video4linux2 -r 15 -s qqvga -i /dev/video0 -f alsa -ac
 1 -i hw:1 -vcodec libx264 -preset ultrafast -g 15 -crf 20 -acodec aac
 -strict experimental -ar 44100 -ab 96k -ac
 1 -f mpegts udp://192.168.25.101:10001
 ffmpeg version N-32427-g22bf6f7, Copyright (c) 2000-2011 the FFmpeg
 developers
   built on Sep 10 2011 06:14:04 with gcc 4.6.1
   configuration: --enable-static --enable-shared --enable-gpl --enable-
 nonfree --enable-postproc --enable-runtime-cpudetect --enable-libx264
 --enable-libaacplus --extra-cflags=-fPIC
   WARNING: library configuration mismatch
   postproc    configuration: --extra-version=4:0.6.2-5 --arch=i386
 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau
 --enable-bzlib --enable-libgsm --enable-libschroedinger --enable-libsp
 eex --enable-libtheora --enable-libvorbis --enable-pthreads --enable-zlib
 --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-
 vaapi --enable-libopenjpeg --enable-gpl --enable-postproc --e
 nable-swscale --enable-x11grab --enable-libfaad --enable-libdirac
 --enable-libfaad --enable-libmp3lame --enable-librtmp --enable-libx264
 --enable-libxvid --enable-libdc1394 --shlibdir=/usr/lib/i686/cmov --cp
 u=i686 --enable-shared --disable-static --disable-ffmpeg --disable-ffplay
   libavutil    51. 16. 0 / 51. 16. 0
   libavcodec   53. 13. 0 / 53. 13. 0
   libavformat  53. 12. 0 / 53. 12. 0
   libavdevice  53.  3. 0 / 53.  3. 0
   libavfilter   2. 39. 0 /  2. 39. 0
   libswscale    2.  1. 0 /  2.  1. 0
   libpostproc  51.  2. 0 / 51.  2. 0
 [video4linux2 @ 0x998fb00] Estimating duration from bitrate, this may be
 inaccurate
 Input #0, video4linux2, from '/dev/video0':
   Duration: N/A, start: 7618.708052, bitrate: 4608 kb/s
     Stream #0.0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 160x120,
 4608 kb/s, 15 tbr, 1000k tbn, 15 tbc
 [alsa @ 0x99906e0] Estimating duration from bitrate, this may be
 inaccurate
 Input #1, alsa, from 'hw:1':
   Duration: N/A, start: 1315632754.420454, bitrate: N/A
     Stream #1.0: Audio: pcm_s16le, 16000 Hz, 1 channels, s16, 256 kb/s
 Incompatible pixel format 'yuyv422' for codec 'libx264', auto-selecting
 format 'yuv420p'
 [buffer @ 0x999ab20] w:160 h:120 pixfmt:yuyv422 tb:1/1000000 sar:0/1
 sws_param:
 [buffersink @ 0x999abc0] auto-inserting filter 'auto-inserted scaler 0'
 between the filter 'src' and the filter 'out'
 [scale @ 0x99961e0] w:160 h:120 fmt:yuyv422 -> w:160 h:120 fmt:yuv420p
 flags:0x4
 [libx264 @ 0x998b7c0] using cpu capabilities: MMX2 SSE2 Cache64
 [libx264 @ 0x998b7c0] profile Constrained Baseline, level 1.0
 [mpegts @ 0x998b040] muxrate VBR, pcr every 1 pkts, sdt every 200, pat/pmt
 every 40 pkts
 Output #0, mpegts, to 'udp://192.168.25.101:10001':
   Metadata:
     encoder         : Lavf53.12.0
     Stream #0.0: Video: h264, yuv420p, 160x120, q=-1--1, 90k tbn, 15 tbc
     Stream #0.1: Audio: aac, 44100 Hz, 1 channels, s16, 96 kb/s
 Stream mapping:
   Stream #0.0 -> #0.0 (rawvideo -> libx264)
   Stream #1.0 -> #0.1 (pcm_s16le -> aac)
 Press [q] to stop, [?] for help
 frame=  288 fps= 17 q=24.0 Lsize=     604kB time=00:00:17.20 bitrate=
 287.6kbits/s dup=30 drop=0
 video:324kB audio:188kB global headers:0kB muxing overhead 17.897995%
 frame I:20    Avg QP:15.81  size:  5393
 [libx264 @ 0x998b7c0] frame P:268   Avg QP:18.68  size:   835
 [libx264 @ 0x998b7c0] mb I  I16..4: 100.0%  0.0%  0.0%
 [libx264 @ 0x998b7c0] mb P  I16..4:  0.5%  0.0%  0.0%  P16..4: 60.0%  0.0%
 0.0%  0.0%  0.0%    skip:39.5%
 [libx264 @ 0x998b7c0] coded y,uvDC,uvAC intra: 90.5% 95.0% 86.3% inter:
 26.5% 48.7% 14.6%
 [libx264 @ 0x998b7c0] i16 v,h,dc,p: 40% 25% 20% 15%
 [libx264 @ 0x998b7c0] i8c dc,h,v,p: 49%  7% 30% 13%
 [libx264 @ 0x998b7c0] kb/s:138.22
 }}}


 This doesn't work (just switched places for audio and video input):

 {{{
 # ffmpeg -isync -f alsa -ac 1 -i hw:1 -f video4linux2 -r 15 -s qqvga -i
 /dev/video0 -vcodec libx264 -preset ultrafast -g 15 -crf 20 -acodec aac
 -strict experimental -ar 44100 -ab 96k -ac 1 -f mpegts
 udp://192.168.25.101:10001
 ffmpeg version N-32427-g22bf6f7, Copyright (c) 2000-2011 the FFmpeg
 developers
   built on Sep 10 2011 06:14:04 with gcc 4.6.1
   configuration: --enable-static --enable-shared --enable-gpl --enable-
 nonfree --enable-postproc --enable-runtime-cpudetect --enable-libx264
 --enable-libaacplus --extra-cflags=-fPIC
   WARNING: library configuration mismatch
   postproc    configuration: --extra-version=4:0.6.2-5 --arch=i386
 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau
 --enable-bzlib --enable-libgsm --enable-libschroedinger --enable-libspeex
 --enable-libtheora --enable-libvorbis --enable-pthreads --enable-zlib
 --enable-libvpx --disable-stripping --enable-runtime-cpudetect --enable-
 vaapi --enable-libopenjpeg --enable-gpl --enable-postproc --enable-swscale
 --enable-x11grab --enable-libfaad --enable-libdirac --enable-libfaad
 --enable-libmp3lame --enable-librtmp --enable-libx264 --enable-libxvid
 --enable-libdc1394 --shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-
 shared --disable-static --disable-ffmpeg --disable-ffplay
   libavutil    51. 16. 0 / 51. 16. 0
   libavcodec   53. 13. 0 / 53. 13. 0
   libavformat  53. 12. 0 / 53. 12. 0
   libavdevice  53.  3. 0 / 53.  3. 0
   libavfilter   2. 39. 0 /  2. 39. 0
   libswscale    2.  1. 0 /  2.  1. 0
   libpostproc  51.  2. 0 / 51.  2. 0
 [alsa @ 0x8303ae0] cannot set parameters (Connection timed out)
 hw:1: Input/output error
 }}}

-- 
Ticket URL: <https://ffmpeg.org/trac/ffmpeg/ticket/449>
FFmpeg <http://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list