Opened 11 years ago

Closed 4 years ago

#2691 closed defect (fixed)

ffmpeg detects 0 channels in audio streams (audio streams are detected after the main loop in find_stream_info)

Reported by: Olivier Owned by:
Priority: normal Component: avformat
Version: git-master Keywords: mpegps
Cc: Blocked By:
Blocking: Reproduced by developer: yes
Analyzed by developer: no

Description

Summary of the bug:
ffmpeg does not detect the audio channels if the audio streams don't have any in the first few seconds.

How to reproduce:

vhann@vhanndinateur ~,0 $ foo/ffmpeg -i outputShortest.vobffmpeg version N-54023-g6fe419b Copyright (c) 2000-2013 the FFmpeg developers
  built on Jun 14 2013 05:12:40 with gcc 4.6 (Debian 4.6.3-1)
  configuration: --prefix=/root/ffmpeg-static/32bit --arch=x86_32 --extra-cflags='-m32 -I/root/ffmpeg-static/32bit/include -static' --extra-ldflags='-m32 -L/root/ffmpeg-static/32bit/lib -static' --extra-libs='-lxml2 -lexpat -lfreetype' --enable-static --disable-shared --disable-ffserver --disable-doc --enable-bzlib --enable-zlib --enable-postproc --enable-runtime-cpudetect --enable-libx264 --enable-gpl --enable-libtheora --enable-libvorbis --enable-libmp3lame --enable-gray --enable-libass --enable-libfreetype --enable-libopenjpeg --enable-libspeex --enable-libvo-aacenc --enable-libvo-amrwbenc --enable-version3 --enable-libvpx
  libavutil      52. 35.101 / 52. 35.101
  libavcodec     55. 16.100 / 55. 16.100
  libavformat    55.  8.102 / 55.  8.102
  libavdevice    55.  2.100 / 55.  2.100
  libavfilter     3. 77.101 /  3. 77.101
  libswscale      2.  3.100 /  2.  3.100
  libswresample   0. 17.102 /  0. 17.102
  libpostproc    52.  3.100 / 52.  3.100
[mpeg @ 0xaaa3060] max_analyze_duration 5000000 reached at 5005000 microseconds
Input #0, mpeg, from 'outputShortest.vob':
  Duration: 00:00:24.46, start: 0.140600, bitrate: 17150 kb/s
    Stream #0:0[0x1bf]: Data: dvd_nav_packet
    Stream #0:1[0x1e0]: Video: mpeg2video (Main), yuv420p, 720x480 [SAR 32:27 DAR 16:9], 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
    Stream #0:2[0x82]: Audio: ac3, 0 channels
    Stream #0:3[0x81]: Audio: ac3, 0 channels
    Stream #0:4[0x80]: Audio: ac3, 0 channels
At least one output file must be specified

-analyzeduration and -probesize make it work though:

vhann@vhanndinateur ~,0 $ foo/ffmpeg -analyzeduration 50000000 -probesize 50000000 -i outputShortest.vob 
ffmpeg version N-54023-g6fe419b Copyright (c) 2000-2013 the FFmpeg developers
  built on Jun 14 2013 05:12:40 with gcc 4.6 (Debian 4.6.3-1)
  configuration: --prefix=/root/ffmpeg-static/32bit --arch=x86_32 --extra-cflags='-m32 -I/root/ffmpeg-static/32bit/include -static' --extra-ldflags='-m32 -L/root/ffmpeg-static/32bit/lib -static' --extra-libs='-lxml2 -lexpat -lfreetype' --enable-static --disable-shared --disable-ffserver --disable-doc --enable-bzlib --enable-zlib --enable-postproc --enable-runtime-cpudetect --enable-libx264 --enable-gpl --enable-libtheora --enable-libvorbis --enable-libmp3lame --enable-gray --enable-libass --enable-libfreetype --enable-libopenjpeg --enable-libspeex --enable-libvo-aacenc --enable-libvo-amrwbenc --enable-version3 --enable-libvpx
  libavutil      52. 35.101 / 52. 35.101
  libavcodec     55. 16.100 / 55. 16.100
  libavformat    55.  8.102 / 55.  8.102
  libavdevice    55.  2.100 / 55.  2.100
  libavfilter     3. 77.101 /  3. 77.101
  libswscale      2.  3.100 /  2.  3.100
  libswresample   0. 17.102 /  0. 17.102
  libpostproc    52.  3.100 / 52.  3.100
[mpeg @ 0xa8d21e0] max_analyze_duration 50000000 reached at 50032489 microseconds
Input #0, mpeg, from 'outputShortest.vob':
  Duration: 00:00:24.50, start: 0.095889, bitrate: 17118 kb/s
    Stream #0:0[0x1bf]: Data: dvd_nav_packet
    Stream #0:1[0x1e0]: Video: mpeg2video (Main), yuv420p, 720x480 [SAR 32:27 DAR 16:9], 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
    Stream #0:2[0x80]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 384 kb/s
    Stream #0:3[0x82]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 384 kb/s
    Stream #0:4[0x81]: Audio: ac3, 48000 Hz, 5.1(side), fltp, 384 kb/s
At least one output file must be specified

llogan and vulture both were valuable in figuring the problem.

Change History (5)

comment:1 by Olivier, 11 years ago

I uploaded the sample under the name "sampleForTicket2691.vob" to http://upload.ffmpeg.org/upload/

comment:2 by Carl Eugen Hoyos, 11 years ago

Component: FFmpegavformat
Keywords: mpegps added; vob dvd aac 0 channels removed
Priority: normalminor
Reproduced by developer: set
Status: newopen
Summary: ffmpeg detects 0 channels in audio streamsffmpeg detects 0 channels in audio streams and does not suggest increasing values for analyzeduration and probesize
Version: unspecifiedgit-master

Patch sent that prints the suggestion about increasing the values for analyzeduration and probesize for the provided sample.

comment:3 by Carl Eugen Hoyos, 11 years ago

Keywords: regression added
Priority: minorimportant

This is now a regression: Current git head does not inform the user that max_analyze_duration was reached and that increasing it could help.

$ ffmpeg -i sampleForTicket2691.vob
ffmpeg version N-54207-ge59fb3f Copyright (c) 2000-2013 the FFmpeg developers
  built on Jun 26 2013 08:55:21 with gcc 4.7 (SUSE Linux)
  configuration: --enable-gpl --disable-indev=jack
  libavutil      52. 37.101 / 52. 37.101
  libavcodec     55. 17.100 / 55. 17.100
  libavformat    55. 10.100 / 55. 10.100
  libavdevice    55.  2.100 / 55.  2.100
  libavfilter     3. 77.101 /  3. 77.101
  libswscale      2.  3.100 /  2.  3.100
  libswresample   0. 17.102 /  0. 17.102
  libpostproc    52.  3.100 / 52.  3.100
Input #0, mpeg, from 'sampleForTicket2691.vob':
  Duration: 00:00:24.46, start: 0.140600, bitrate: 17150 kb/s
    Stream #0:0[0x1bf]: Data: dvd_nav_packet
    Stream #0:1[0x1e0]: Video: mpeg2video (Main), yuv420p, 720x480 [SAR 32:27 DAR 16:9], 29.97 fps, 29.97 tbr, 90k tbn, 59.94 tbc
    Stream #0:2[0x82]: Audio: ac3, 0 channels
    Stream #0:3[0x81]: Audio: ac3, 0 channels
    Stream #0:4[0x80]: Audio: ac3, 0 channels
At least one output file must be specified

comment:4 by Michael Niedermayer, 11 years ago

Keywords: regression removed
Priority: importantnormal
Summary: ffmpeg detects 0 channels in audio streams and does not suggest increasing values for analyzeduration and probesizeffmpeg detects 0 channels in audio streams (audio streams are detected after the main loop in find_stream_info)

Lack of suggestion fixed in 2492f7774f6c763b23c65d30a2eeb558ea23f4a2

comment:5 by Balling, 4 years ago

Resolution: fixed
Status: openclosed
Note: See TracTickets for help on using tickets.