#1850 closed defect (invalid)
version 1.0-tessus can't encode from DV to MP4
Reported by: | Chris Marrin | Owned by: | |
---|---|---|---|
Priority: | normal | Component: | ffmpeg |
Version: | 1.0 | Keywords: | |
Cc: | Blocked By: | ||
Blocking: | Reproduced by developer: | no | |
Analyzed by developer: | no |
Description
Using ffmpeg version 1.0-tessus (obtained from http://www.evermeet.cx/ffmpeg/). Run:
ffmpeg -i input.dv output.mp4
produces a file with black video, while:
ffmpeg -i input.dv output.avi
produces correct video
The same thing happens with ffmpeg version 0.11.1-tessus.
But when I try to do the DV -> MP4 encoding using FFmpeg version SVN-r15883, which is a version I built a while back using macports it performs correctly.
Here is the output from a failed run:
====================
ffmpeg version 1.0-tessus Copyright (c) 2000-2012 the FFmpeg developers
built on Sep 28 2012 22:31:27 with llvm-gcc 4.2.1 (LLVM build 2336.1.00)
configuration: --prefix=/Users/tessus/data/ext/ffmpeg/sw --as=yasm --extra-version=tessus --disable-shared --enable-static --disable-ffplay --disable-ffserver --enable-gpl --enable-pthreads --enable-postproc --enable-libmp3lame --enable-libtheora --enable-libvorbis --enable-libx264 --enable-libxvid --enable-libspeex --enable-bzlib --enable-zlib --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libxavs --enable-version3 --enable-libvo-aacenc --enable-libvo-amrwbenc --enable-libvpx --enable-libgsm --enable-libopus --enable-fontconfig --enable-libfreetype --enable-libass --enable-filters --enable-runtime-cpudetect
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
libpostproc 52. 0.100 / 52. 0.100
[dv @ 0x102006a00] Estimating duration from bitrate, this may be inaccurate
Input #0, dv, from 'TextAquarium.dv':
Metadata:
timecode : 00:00:00;00
Duration: 00:00:10.04, start: 0.000000, bitrate: 28771 kb/s
Stream #0:0: Video: dvvideo, yuv411p, 720x480 [SAR 8:9 DAR 4:3], 28771 kb/s, 29.97 tbr, 29.97 tbn, 29.97 tbc
File 'foo.mp4' already exists. Overwrite ? [y/N] y
using SAR=8/9
[libx264 @ 0x102018400] using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.2
[libx264 @ 0x102018400] profile High 4:2:2, level 3.0, 4:2:2 8-bit
[libx264 @ 0x102018400] 264 - core 125 - H.264/MPEG-4 AVC codec - Copyleft 2003-2012 - 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=12 lookahead_threads=2 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 'foo.mp4':
Metadata:
timecode : 00:00:00;00
encoder : Lavf54.29.104
Stream #0:0: Video: h264 ([33][0][0][0] / 0x0021), yuv422p, 720x480 [SAR 8:9 DAR 4:3], q=-1--1, 30k tbn, 29.97 tbc
Stream mapping:
Press [q] to stop, ? for help
TextAquarium.dv: Input/output error 382kB time=00:00:06.20 bitrate= 504.1kbits/s
frame= 301 fps=132 q=-2.0 Lsize= 694kB time=00:00:09.97 bitrate= 570.0kbits/s
video:690kB audio:0kB subtitle:0 global headers:0kB muxing overhead 0.626990%
[libx264 @ 0x102018400] frame I:2 Avg QP:18.84 size: 23439
[libx264 @ 0x102018400] frame P:118 Avg QP:23.36 size: 4244
[libx264 @ 0x102018400] frame B:181 Avg QP:25.62 size: 873
[libx264 @ 0x102018400] consecutive B-frames: 0.7% 51.2% 18.9% 29.2%
[libx264 @ 0x102018400] mb I I16..4: 24.6% 59.6% 15.7%
[libx264 @ 0x102018400] mb P I16..4: 5.9% 7.6% 0.1% P16..4: 38.0% 9.9% 3.9% 0.0% 0.0% skip:34.7%
[libx264 @ 0x102018400] mb B I16..4: 0.4% 0.4% 0.0% B16..8: 30.5% 1.4% 0.1% direct: 0.8% skip:66.4% L0:36.9% L1:61.6% BI: 1.5%
[libx264 @ 0x102018400] 8x8 transform intra:55.9% inter:82.7%
[libx264 @ 0x102018400] coded y,uvDC,uvAC intra: 29.8% 66.5% 7.2% inter: 6.0% 20.7% 0.6%
[libx264 @ 0x102018400] i16 v,h,dc,p: 22% 56% 12% 10%
[libx264 @ 0x102018400] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 12% 31% 46% 1% 2% 1% 3% 1% 2%
[libx264 @ 0x102018400] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 22% 28% 15% 6% 6% 6% 6% 4% 7%
[libx264 @ 0x102018400] i8c dc,h,v,p: 48% 35% 14% 3%
[libx264 @ 0x102018400] Weighted P-Frames: Y:0.0% UV:0.0%
[libx264 @ 0x102018400] ref P L0: 68.5% 8.0% 17.5% 6.0%
[libx264 @ 0x102018400] ref B L0: 89.6% 9.6% 0.8%
[libx264 @ 0x102018400] ref B L1: 96.0% 4.0%
[libx264 @ 0x102018400] kb/s:562.10
====================
and here is a successful run:
====================
Input #0, dv, from 'TextAquarium.dv':
Duration: 00:00:10.04, start: 0.000000, bitrate: 28771 kb/s
Stream #0.0: Video: dvvideo, yuv411p, 720x480, 28771 kb/s, 29.97 tb(r)
File 'foo.mp4' already exists. Overwrite ? [y/N] y
FFmpeg version SVN-r15883, Copyright (c) 2000-2008 Fabrice Bellard, et al.
configuration: --disable-ffplay --disable-ffserver --enable-gpl --enable-postproc --enable-swscale --enable-avfilter --enable-avfilter-lavf --disable-vhook --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libvorbis --enable-libtheora --enable-libx264 --enable-libxvid
libavutil 49.12. 0 / 49.12. 0
libavcodec 52. 3. 0 / 52. 3. 0
libavformat 52.23. 1 / 52.23. 1
libavdevice 52. 1. 0 / 52. 1. 0
libavfilter 0. 1. 0 / 0. 1. 0
libswscale 0. 6. 1 / 0. 6. 1
libpostproc 51. 2. 0 / 51. 2. 0
built on Jan 12 2009 07:55:22, gcc: 4.0.1 (Apple Inc. build 5490)
Output #0, mp4, to 'foo.mp4':
Stream #0.0: Video: mpeg4, yuv420p, 720x480 [PAR 10:11 DAR 15:11], q=2-31, 200 kb/s, 29.97 tb(c)
Stream mapping:
Press [q] to stop encoding
frame= 301 fps=222 q=13.5 Lsize= 428kB time=10.04 bitrate= 349.4kbits/s
video:425kB audio:0kB global headers:0kB muxing overhead 0.728407%
====================
The test file I was using was a file that was actually created using an older version of ffmpeg. As you can see it had no audio, only a video stream. But that file is 35MB, so I won't upload it. I also tried a short (1.5MB) DV clip from a Sony DV camcorder. It fails in the same way, so I have attached it.
Attachments (1)
Change History (4)
by , 12 years ago
comment:2 by , 12 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Problem is when converting yuv411p to h264 codec in an mp4 the encoder autoselects the yuv422p colorspace, which is totally valid calorspace. But Quicktime does not support it. Try VLC and you'll see it is a valid file.
Btw. when converting to avi, the encoder autoselects mpeg4 codec and yuv420p colorspace.
comment:3 by , 12 years ago
In other words, add -pix_fmt yuv420p
to your command when encoding with libx264 from DV if you want the output to be playable by QuickTime. ffmpeg will tell you in the console output if libx264 is being used.
Short DV clip showing problem