Opened 6 years ago

Closed 5 years ago

#5163 closed defect (fixed)

[aac @ 0x1c11420] element type mismatch 1 != 0

Reported by: Weiwu Zhang Owned by:
Priority: minor Component: avcodec
Version: git-master Keywords: mov aac regression
Cc: ami_stuff@o2.pl Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Summary of the bug:

Certain .mp4 files, when used as input, triggers this error.

The output file plays silent, no matter what encoding method is used for the output file.

An example of such file is uploaded to ftp://upload.ffmpeg.org and filename is aac_element_type_mismatch.mp4

How to reproduce:

> ffmpeg -i aac_element_type_mismatch.mp4 -c:v copy result.mp4
ffmpeg version 2.8.4 Copyright (c) 2000-2015 the FFmpeg developers
  built with gcc 4.8 (SUSE Linux)
  configuration: --prefix=/usr --libdir=/usr/lib64 --shlibdir=/usr/lib64 --incdir=/usr/include/ffmpeg --extra-cflags='-fmessage-length=0 -grecord-gcc-switches -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -g' --optflags='-fmessage-length=0 -grecord-gcc-switches -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -g' --disable-htmlpages --enable-pic --disable-stripping --enable-shared --disable-static --enable-runtime-cpudetect --enable-gpl --disable-openssl --enable-avresample --enable-libcdio --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libcelt --enable-libcdio --enable-libdc1394 --enable-libfreetype --enable-libgsm --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libwebp --enable-pic --enable-pthreads --enable-vaapi --enable-vdpau --disable-decoder=dca --enable-libdcadec --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-version3 --enable-libtwolame --enable-libvo-aacenc --enable-libx264 --enable-libx265 --enable-libxvid --enable-x11grab
  libavutil      54. 31.100 / 54. 31.100
  libavcodec     56. 60.100 / 56. 60.100
  libavformat    56. 40.101 / 56. 40.101
  libavdevice    56.  4.100 / 56.  4.100
  libavfilter     5. 40.101 /  5. 40.101
  libavresample   2.  1.  0 /  2.  1.  0
  libswscale      3.  1.101 /  3.  1.101
  libswresample   1.  2.101 /  1.  2.101
  libpostproc    53.  3.100 / 53.  3.100
[aac @ 0x1c101c0] element type mismatch 1 != 0
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'aac_element_type_mismatch.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf56.40.101
  Duration: 00:00:30.02, start: 0.000000, bitrate: 2623 kb/s
    Stream #0:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuv420p, 720x576 [SAR 1:1 DAR 5:4], 2492 kb/s, 25 fps, 25 tbr, 30k tbn, 20000k tbc (default)
    Metadata:
      handler_name    : VideoHandler
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 96000 Hz, stereo, fltp, 127 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
[mp4 @ 0x1c49220] Codec for stream 0 does not use global headers but container format requires global headers
Output #0, mp4, to 'result.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf56.40.101
    Stream #0:0(und): Video: h264 ([33][0][0][0] / 0x0021), yuv420p, 720x576 [SAR 1:1 DAR 5:4], q=2-31, 2492 kb/s, 25 fps, 25 tbr, 30k tbn, 30k tbc (default)
    Metadata:
      handler_name    : VideoHandler
    Stream #0:1(und): Audio: aac (libvo_aacenc) ([64][0][0][0] / 0x0040), 96000 Hz, stereo, s16, 128 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
      encoder         : Lavc56.60.100 libvo_aacenc
Stream mapping:
  Stream #0:0 -> #0:0 (copy)
  Stream #0:1 -> #0:1 (aac (native) -> aac (libvo_aacenc))
Press [q] to stop, [?] for help
[aac @ 0x1c11420] element type mismatch 1 != 0
    Last message repeated 316 times
[aac @ 0x1c11420] element type mismatch 1 != 0e=00:00:06.76 bitrate=1283.4kbits/s    
    Last message repeated 320 times
[aac @ 0x1c11420] element type mismatch 1 != 0e=00:00:13.59 bitrate=1946.4kbits/s    
    Last message repeated 307 times
[aac @ 0x1c11420] element type mismatch 1 != 0e=00:00:20.16 bitrate=2383.5kbits/s    
    Last message repeated 351 times
[aac @ 0x1c11420] element type mismatch 1 != 0e=00:00:27.68 bitrate=2581.3kbits/s    
    Last message repeated 108 times
frame=  750 fps=342 q=-1.0 Lsize=    9620kB time=00:00:30.02 bitrate=2625.0kbits/s    
video:9126kB audio:468kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.266198%

Attachments (1)

DVD1-奇怪的喇叭声_cut.mp4 (2.4 MB ) - added by Carl Eugen Hoyos 6 years ago.

Change History (10)

in reply to:  description comment:1 by Carl Eugen Hoyos, 6 years ago

Keywords: mov aac added

Replying to zhangweiwu:

The output file plays silent, no matter what encoding method is used for the output file.

How I can I reproduce this? The output file plays fine here.

How did you produce the input file?

comment:2 by Weiwu Zhang, 6 years ago

How I can I reproduce this? The output file plays fine here.

The source file plays fine on Windows Media Player version 12 (shipped with Windows 7), the output plays silently, so I thought it is caused by the only error message '[aac @ 0x1c11420] element type mismatch 1 != 0'

Since it played fine with you, I retested playback with QuickTime, and the output was as you said, fine.

In that case, the problem (output AAC plays silently on WMP) probably is another issue filed somewhere else already and unrelated to the error message.

How did you produce the input file?

    $ ffmpeg -i full-video.mp4 -t 30 -c copy aac_element_type_mismatch.mp4
Last edited 6 years ago by Weiwu Zhang (previous) (diff)

comment:3 by Carl Eugen Hoyos, 6 years ago

Please upload full-video.mp4.

in reply to:  3 comment:4 by Weiwu Zhang, 6 years ago

Replying to cehoyos:

Please upload full-video.mp4.

Posting guide suggests not to post videos larger than 500MB. If you insist I'll upload the whole 600MB. Thanks.

Last edited 6 years ago by Weiwu Zhang (previous) (diff)

comment:5 by Carl Eugen Hoyos, 6 years ago

Please upload full-video.mp4.

comment:6 by Weiwu Zhang, 6 years ago

The full-video.mp4 is uploaded as DVD1-奇怪的喇叭声.mp4 (611957424 bytes) to ftp://upload.ffmpeg.org/incoming

Last edited 6 years ago by Weiwu Zhang (previous) (diff)

comment:7 by Carl Eugen Hoyos, 6 years ago

Component: undeterminedavcodec
Keywords: regression added
Priority: normalminor
Status: newopen
Version: unspecifiedgit-master

The main issue is that afaict WMP does not support 96kHz aac, workaround is to use -ar 48k.
The input sample uses SBR (which kind of doubles the sample rate), WMP is definitely playing it, no matter how often I remux it (or to which container). Reencoding with FFmpeg leads to 96kHz (without SBR) which isn't played by WMP.
One issue I see is that FFmpeg doesn't show that the sample uses SBR, the other issues are the warnings that are a regression since 79a98294da6cd85f8c86b34764c5e0c43b09eea3

in reply to:  7 comment:8 by ami_stuff, 6 years ago

Cc: ami_stuff@o2.pl added

Replying to cehoyos:

the other issues are the warnings that are a regression since 79a98294da6cd85f8c86b34764c5e0c43b09eea3

I see this issue with one of my samples as well:

http://www.datafilehost.com/d/25677e94

by Carl Eugen Hoyos, 6 years ago

comment:9 by Elon Musk, 5 years ago

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