[FFmpeg-user] MP4Box can't mux ffmpeg x264 output: "IsoMedia File is truncated"

sean darcy seandarcy2 at gmail.com
Sun Apr 3 16:36:30 CEST 2011


Using yesterday's git, I'm trying to make an android playable mp4.

Here's the script full-level3-nero-mp4box:

INPUT=total.file
ffmpeg -i $INPUT -an -pass 1  -vcodec libx264 -level 30 -vpre 
slower_firstpass     \
        -bufsize 10000000 -maxrate 10000000 -b 10000000 -threads 0 -f 
mp4 -y /dev/null
ffmpeg -i $INPUT -an -pass 2  -vcodec libx264 -level 30 -vpre slower 
-timestamp now \
        -bufsize 10000000 -maxrate 10000000 -b 10000000 -threads 0 $1.m4v

ffmpeg -i $INPUT -vn -acodec copy -f wav - | neroAacEnc -q 0.3 
-ignorelength  -if -  -of $1.m4a
MP4Box -fps 29.97 -add $1.m4v -add $1.m4a          -new           $1.mp4

I'm using MP4Box from this week:

MP4Box -version
MP4Box - GPAC version 0.4.6-DEV-rev2812M


The command ./full-level3-nero-mp4box full-test runs fine until:

+ MP4Box -fps 29.97 -add full-test.m4v -add full-test.m4a -new full-test.mp4
[iso file] Incomplete box ..5.
[iso file] Incomplete box ..5.

MP4Box thinks full-test.m4a is fine but not m4v:

MP4Box -info full-test.m4v
[iso file] Incomplete box ..5.
[iso file] Incomplete box ..5.
Truncated file - missing 1219279998 bytes
Error opening file full-test.m4v: IsoMedia File is truncated

FWIW:

14854937328 Apr  2 16:36 total.file
4962718305 Apr  3 02:25 full-test.m4v

ffprobe full-test.m4v
FFprobe version git-N-28804-gf38fa75, Copyright (c) 2007-2011 the FFmpeg 
developers
   built on Apr  2 2011 23:14:01 with gcc 4.5.1 20100924 (Red Hat 4.5.1-4)
   configuration: --prefix=/usr --bindir=/usr/bin 
--datadir=/usr/share/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man 
--shlibdir=/usr/lib64 --extra-cflags='-O2 -march=native -mtune=native 
-fopenmp -fomit-frame-pointer -pipe' --enable-static --enable-shared 
--enable-gpl --enable-nonfree --enable-version3 --enable-postproc 
--enable-avfilter --enable-pthreads --enable-x11grab --enable-gray 
--enable-vaapi --enable-hardcoded-tables --enable-frei0r 
--enable-libopencv --enable-libdirac --disable-decoder=libdirac 
--enable-libgsm --enable-libmp3lame --enable-libopenjpeg 
--enable-librtmp --enable-libschroedinger 
--disable-encoder=libschroedinger --enable-libspeex --enable-libtheora 
--enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxvid 
--enable-zlib --disable-debug --cpu=amdfam10 --arch=x86_64 --enable-pic
   libavutil    50. 40. 0 / 50. 40. 0
   libavcodec   52.117. 0 / 52.117. 0
   libavformat  52.104. 0 / 52.104. 0
   libavdevice  52.  4. 0 / 52.  4. 0
   libavfilter   1. 76. 0 /  1. 76. 0
   libswscale    0. 13. 0 /  0. 13. 0
   libpostproc  51.  2. 0 / 51.  2. 0
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'full-test.m4v':
   Metadata:
     major_brand     : M4V
     minor_version   : 512
     compatible_brands: isomiso2avc1
     creation_time   : 2011-04-03 03:39:34
     encoder         : Lavf52.104.0
   Duration: 01:06:26.64, start: 0.000000, bitrate: 9958 kb/s
     Stream #0.0(und): Video: h264 (High), yuv420p, 720x480 [PAR 8:9 DAR 
4:3], 9953 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc
     Metadata:
       creation_time   : 2011-04-03 03:39:34

ffprobe total.file
.......
Input #0, avi, from 'total.file':
   Duration: 00:00:06.60, start: 0.000000, bitrate: -2147483 kb/s
     Stream #0.0: Video: dvvideo, yuv411p, 720x480 [PAR 8:9 DAR 4:3], 
29.97 tbr, 29.97 tbn, 29.97 tbc
     Stream #0.1: Audio: pcm_s16le, 32000 Hz, 2 channels, s16, 1024 kb/s


Is this related to the odd tbn and tbr in full-test.m4v? From an earlier 
thread, I thought that didn't matter.

But if not that, what is causing the failure?

sean




More information about the ffmpeg-user mailing list