#5982 closed defect (fixed)

ffmpeg unable to extract video stream from mov container

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

Description (last modified by cehoyos)

I have a mov video file of which i'm unable to extract the videostream.
info from ffprobe:

> ffprobe 451709-1990-SEM90E-CadillacReveal-PGM.mov
ffprobe version N-81872-gbe1d324 Copyright (c) 2007-2016 the FFmpeg developers
  built with gcc 5.4.0 (GCC)
  configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-dxva2 --enable-libmfx --enable-nvenc --enable-avisynth --enable-bzlib --enable-libebur128 --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libschroedinger --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-lzma --enable-decklink --enable-zlib
  libavutil      55. 32.100 / 55. 32.100
  libavcodec     57. 60.101 / 57. 60.101
  libavformat    57. 51.102 / 57. 51.102
  libavdevice    57.  0.102 / 57.  0.102
  libavfilter     6. 63.100 /  6. 63.100
  libswscale      4.  1.100 /  4.  1.100
  libswresample   2.  2.100 /  2.  2.100
  libpostproc    54.  0.100 / 54.  0.100
[mov,mp4,m4a,3gp,3g2,mj2 @ 0000000000e096c0] multiple fourcc not supported
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '451709-1990-SEM90E-CadillacReveal-PGM.mov':
  Metadata:
    major_brand     : qt
    minor_version   : 537199360
    compatible_brands: qt
    creation_time   : 2013-12-11T17:48:01.000000Z
    timecode        : 20:29:57:24
  Duration: 00:01:07.43, start: 0.000000, bitrate: 214167 kb/s
    Stream #0:0(eng): Video: rawvideo (AV1x / 0x78315641), uyvy422(pc), 720x486, 212630 kb/s, 29.97 fps, 29.97 tbr, 29970 tbn, 29970 tbc (default)
    Metadata:
      creation_time   : 2013-12-11T17:48:01.000000Z
      handler_name    : Apple Alias Data Handler
      encoder         : Avid MXF1:1
    Stream #0:1(eng): Audio: pcm_s16be (twos / 0x736F7774), 48000 Hz, stereo, s16, 1536 kb/s (default)
    Metadata:
      creation_time   : 2013-12-11T17:48:01.000000Z
      handler_name    : Apple Alias Data Handler
    Stream #0:2(eng): Data: none (tmcd / 0x64636D74) (default)
    Metadata:
      creation_time   : 2013-12-11T17:48:19.000000Z
      handler_name    : Apple Alias Data Handler
      timecode        : 20:29:57:24
Unsupported codec with id 0 for input stream 2`

At first I thought it was simply a codec that was not supported by ffmpeg. But after some trial and error i noticed that mplayer is able to extract the video stream while using ffmpeg and all i needed to specify is that it was a mov container:
mplayer -demuxer mov videofile.mov

If necessary i can provide a sample video file to demonstrate this defect.

Change History (9)

comment:1 Changed 15 months ago by cehoyos

  • Description modified (diff)

To make this a valid ticket, please test current FFmpeg git head and provide the ffmpeg command line that you tested together with the complete, uncut console output (only provide ffprobe output if the issue you is only reproducible with ffprobe) and a sample.

comment:2 Changed 15 months ago by elangelo

Tested with the ffmpeg from git.
The ffmpeg command line i'm trying:

$ ffmpeg -y -i 451709-1990-SEM90E-CadillacReveal-PGM.mov -t 5 -c:v h264 -c:a aac test.mp4
ffmpeg version N-82288-gacd87df Copyright (c) 2000-2016 the FFmpeg developers
  built with gcc 6.2.1 (GCC) 20160830
  configuration: --prefix=/usr --disable-debug --disable-static --enable-avisynth --enable-avresample --enable-fontconfig --enable-gnutls --enable-gpl --enable-ladspa --enable-libass --enable-libbluray --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopus --enable-libfdk-aac --enable-libpulse --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libv4l2 --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxvid --enable-nonfree --enable-shared --enable-version3 --enable-x11grab
  libavutil      55. 35.100 / 55. 35.100
  libavcodec     57. 66.101 / 57. 66.101
  libavformat    57. 57.100 / 57. 57.100
  libavdevice    57.  2.100 / 57.  2.100
  libavfilter     6. 66.100 /  6. 66.100
  libavresample   3.  2.  0 /  3.  2.  0
  libswscale      4.  3.100 /  4.  3.100
  libswresample   2.  4.100 /  2.  4.100
  libpostproc    54.  2.100 / 54.  2.100
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x560f82e5ba60] multiple fourcc not supported
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '451709-1990-SEM90E-CadillacReveal-PGM.mov':
  Metadata:
    major_brand     : qt  
    minor_version   : 537199360
    compatible_brands: qt  
    creation_time   : 2013-12-11T17:48:01.000000Z
    timecode        : 20:29:57:24
  Duration: 00:01:07.43, start: 0.000000, bitrate: 214167 kb/s
    Stream #0:0(eng): Video: rawvideo (AV1x / 0x78315641), uyvy422(pc), 720x486, 212630 kb/s, 29.97 fps, 29.97 tbr, 29970 tbn, 29970 tbc (default)
    Metadata:
      creation_time   : 2013-12-11T17:48:01.000000Z
      handler_name    : Apple Alias Data Handler
      encoder         : Avid MXF1:1
    Stream #0:1(eng): Audio: pcm_s16be (twos / 0x736F7774), 48000 Hz, stereo, s16, 1536 kb/s (default)
    Metadata:
      creation_time   : 2013-12-11T17:48:01.000000Z
      handler_name    : Apple Alias Data Handler
    Stream #0:2(eng): Data: none (tmcd / 0x64636D74) (default)
    Metadata:
      creation_time   : 2013-12-11T17:48:19.000000Z
      handler_name    : Apple Alias Data Handler
      timecode        : 20:29:57:24
No pixel format specified, yuv422p for H.264 encoding chosen.
Use -pix_fmt yuv420p for compatibility with outdated media players.
[libx264 @ 0x560f82e6dd20] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 AVX2 LZCNT BMI2
[libx264 @ 0x560f82e6dd20] profile High 4:2:2, level 3.1, 4:2:2 8-bit
[libx264 @ 0x560f82e6dd20] 264 - core 148 r2708 86b7198 - H.264/MPEG-4 AVC codec - Copyleft 2003-2016 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=6 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=crf mbtree=1 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mp4, to 'test.mp4':
  Metadata:
    major_brand     : qt  
    minor_version   : 537199360
    compatible_brands: qt  
    timecode        : 20:29:57:24
    encoder         : Lavf57.57.100
    Stream #0:0(eng): Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv422p, 720x486, q=-1--1, 29.97 fps, 11988 tbn, 29.97 tbc (default)
    Metadata:
      creation_time   : 2013-12-11T17:48:01.000000Z
      handler_name    : Apple Alias Data Handler
      encoder         : Lavc57.66.101 libx264
    Side data:
      cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
    Stream #0:1(eng): Audio: aac (LC) ([64][0][0][0] / 0x0040), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      creation_time   : 2013-12-11T17:48:01.000000Z
      handler_name    : Apple Alias Data Handler
      encoder         : Lavc57.66.101 aac
Stream mapping:
  Stream #0:0 -> #0:0 (rawvideo (native) -> h264 (libx264))
  Stream #0:1 -> #0:1 (pcm_s16be (native) -> aac (native))
Press [q] to stop, [?] for help
frame=  150 fps=0.0 q=-1.0 Lsize=      29kB time=00:00:05.01 bitrate=  46.8kbits/s dup=151 drop=0 speed=15.8x    
video:4kB audio:17kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 32.985672%
[libx264 @ 0x560f82e6dd20] frame I:1     Avg QP:10.00  size:   116
[libx264 @ 0x560f82e6dd20] frame P:38    Avg QP:10.21  size:    31
[libx264 @ 0x560f82e6dd20] frame B:111   Avg QP:13.67  size:    23
[libx264 @ 0x560f82e6dd20] consecutive B-frames:  1.3%  0.0%  0.0% 98.7%
[libx264 @ 0x560f82e6dd20] mb I  I16..4: 100.0%  0.0%  0.0%
[libx264 @ 0x560f82e6dd20] mb P  I16..4:  0.0%  0.0%  0.0%  P16..4:  0.0%  0.0%  0.0%  0.0%  0.0%    skip:100.0%
[libx264 @ 0x560f82e6dd20] mb B  I16..4:  0.0%  0.0%  0.0%  B16..8:  0.0%  0.0%  0.0%  direct: 0.0%  skip:100.0%
[libx264 @ 0x560f82e6dd20] 8x8 transform intra:0.0%
[libx264 @ 0x560f82e6dd20] coded y,uvDC,uvAC intra: 0.0% 0.0% 0.0% inter: 0.0% 0.0% 0.0%
[libx264 @ 0x560f82e6dd20] i16 v,h,dc,p: 97%  0%  3%  0%
[libx264 @ 0x560f82e6dd20] i8c dc,h,v,p: 100%  0%  0%  0%
[libx264 @ 0x560f82e6dd20] Weighted P-Frames: Y:0.0% UV:0.0%
[libx264 @ 0x560f82e6dd20] kb/s:6.07
[aac @ 0x560f82e6f0c0] Qavg: 57410.969

The console output looks ok to me. Only if you try to play test.mp4 the video stream is actually just black output, while the original movie does contain actual video data. (so not just black output)

I would like to upload a sample but the smallest file i could reproduce this with is 20MB. That is too big to attach to this ticket. I've also tried to upload it to upload.ffmpeg.org as instructed on the wiki but it seems like that ftp server is down? Any other way i can provide you with the sample file?

Last edited 15 months ago by elangelo (previous) (diff)

comment:3 Changed 15 months ago by cehoyos

Please use a file host of your choice, for example datafilehost.com.

comment:4 Changed 15 months ago by elangelo

https://www.datafilehost.com/d/2e75bf70

i hope this works.
I prepared the original with faststart and then took 20MB of that file with dd to this new file. So though it's not exactly the same like the original it does show exactly the same problem like the original

comment:5 Changed 15 months ago by cehoyos

  • Component changed from undetermined to avformat
  • Keywords mov avid added
  • Reproduced by developer set
  • Status changed from new to open
  • Version changed from unspecified to git-master

Patch sent.

comment:6 Changed 15 months ago by elangelo

Cehoyos, your last comment says 'Patch sent'. What does that mean?

comment:7 Changed 15 months ago by cehoyos

It means that I sent a patch to the development mailing list:
http://ffmpeg.org/pipermail/ffmpeg-devel/2016-November/203661.html

comment:8 Changed 15 months ago by elangelo

This patch works for me. Is there any chance of getting this merged?

comment:9 Changed 14 months ago by cehoyos

  • Resolution set to fixed
  • Status changed from open to closed
Note: See TracTickets for help on using tickets.