[FFmpeg-user] wrong number of ref frames
Chourasia, Amit
amit at sdsc.edu
Tue Dec 17 20:33:51 CET 2013
I agree that the variable -ref values in preset did cause some grief. You could possibly modify and create your own preset as I had trouble passing --ref 4 in the command line and preset option.
I plan to append to this thread when I am back from travel as I am having artifacts show up with slower and medium presets as well with default and level 5.1 profiles.
-A
> On Dec 17, 2013, at 1:04 PM, "Elliott Balsley" <elliottbalsley at gmail.com> wrote:
>
> Thanks, using ‘slower’ preset fixes the glitches in QuickTime, and uses 8 ref frames, as expected. I suppose I could manually specify 9 if I wanted to. Is this a bug? I thought profile and level restrictions are supposed to override all other settings.
>
>> On Dec 17, 2013, at 10:43 AM, Chourasia, Amit <amit at sdsc.edu> wrote:
>>
>> The veryslow preset causes that. Try slower preset, I am also having same problem with QuickTime.
>>
>> -A
>>
>>
>>> On Dec 17, 2013, at 12:37 PM, "Elliott Balsley" <elliottbalsley at gmail.com> wrote:
>>>
>>> I used ffmpeg to encode a video with libx264, using High Profile @ Level 4.1. So the reference frames should be 9. But it’s actually using 16. Can anyone figure out why? The encode also displays major visual artifacts in QuickTime Player 7 (see attached screenshot), which I’m guessing might be caused by the too many ref frames. It plays fine in VLC.
>>>
>>> Screenshot: https://www.dropbox.com/s/fi8hwrf5u3jrl0r/blocky.jpg
>>>
>>> $ ffmpeg -i short\ cut\ 12-16\ lock.mov -pix_fmt yuv420p -vf scale=hd720 -acodec libfdk_aac -b:a 128k -vcodec libx264 -preset veryslow -crf 19 -profile high -level 41 shortCRF19.mov
>>> ffmpeg version N-57394-gea9632b Copyright (c) 2000-2013 the FFmpeg developers
>>> built on Oct 24 2013 11:58:12 with Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
>>> configuration: --enable-gpl --enable-version3 --enable-nonfree --enable-static --enable-libass --enable-libbluray --enable-libfdk-aac --enable-libmp3lame --enable-libvpx --enable-libx264 --enable-opencl --enable-libfreetype --disable-shared --enable-libopenjpeg --enable-libvorbis --enable-libtheora
>>> libavutil 52. 47.101 / 52. 47.101
>>> libavcodec 55. 38.101 / 55. 38.101
>>> libavformat 55. 19.104 / 55. 19.104
>>> libavdevice 55. 5.100 / 55. 5.100
>>> libavfilter 3. 89.100 / 3. 89.100
>>> libswscale 2. 5.101 / 2. 5.101
>>> libswresample 0. 17.104 / 0. 17.104
>>> libpostproc 52. 3.100 / 52. 3.100
>>> Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'short cut 12-16 lock.mov':
>>> Metadata:
>>> major_brand : qt
>>> minor_version : 537199360
>>> compatible_brands: qt
>>> creation_time : 2013-12-17 08:50:12
>>> Duration: 00:05:42.01, start: 0.000000, bitrate: 166700 kb/s
>>> Stream #0:0(eng): Video: prores (apch / 0x68637061), yuv422p10le, 1920x1080, 165139 kb/s, SAR 1:1 DAR 16:9, 23.98 fps, 23.98 tbr, 24k tbn, 24k tbc (default)
>>> Metadata:
>>> creation_time : 2013-12-17 08:50:12
>>> handler_name : Apple Alias Data Handler
>>> timecode : 00:00:03:00
>>> Stream #0:1(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz, stereo, s16, 1536 kb/s (default)
>>> Metadata:
>>> creation_time : 2013-12-17 08:50:12
>>> handler_name : Apple Alias Data Handler
>>> timecode : 00:00:03:00
>>> Stream #0:2(eng): Data: none (tmcd / 0x64636D74) (default)
>>> Metadata:
>>> creation_time : 2013-12-17 08:50:12
>>> handler_name : Apple Alias Data Handler
>>> timecode : 00:00:03:00
>>> Please use -profile:a or -profile:v, -profile is ambiguous
>>> [libx264 @ 0x7ffb41809a00] using SAR=1/1
>>> [libx264 @ 0x7ffb41809a00] DPB size (16 frames, 57600 mbs) > level limit (9 frames, 32768 mbs)
>>> [libx264 @ 0x7ffb41809a00] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2
>>> [libx264 @ 0x7ffb41809a00] profile High, level 4.1
>>> [libx264 @ 0x7ffb41809a00] 264 - core 138 r2358 9e941d1 - H.264/MPEG-4 AVC codec - Copyleft 2003-2013 - http://www.videolan.org/x264.html - options: cabac=1 ref=16 deblock=1:0:0 analyse=0x3:0x133 me=umh subme=10 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=24 chroma_me=1 trellis=2 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=24 lookahead_threads=4 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=8 b_pyramid=2 b_adapt=2 b_bias=0 direct=3 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=23 scenecut=40 intra_refresh=0 rc_lookahead=60 rc=crf mbtree=1 crf=19.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
>>> Output #0, mov, to 'shortCRF19.mov':
>>> Metadata:
>>> major_brand : qt
>>> minor_version : 537199360
>>> compatible_brands: qt
>>> encoder : Lavf55.19.104
>>> Stream #0:0(eng): Video: h264 (libx264) (avc1 / 0x31637661), yuv420p, 1280x720 [SAR 1:1 DAR 16:9], q=-1--1, 24k tbn, 23.98 tbc (default)
>>> Metadata:
>>> creation_time : 2013-12-17 08:50:12
>>> handler_name : Apple Alias Data Handler
>>> timecode : 00:00:03:00
>>> Stream #0:1(eng): Audio: aac (libfdk_aac) (mp4a / 0x6134706D), 48000 Hz, stereo, s16, 128 kb/s (default)
>>> Metadata:
>>> creation_time : 2013-12-17 08:50:12
>>> handler_name : Apple Alias Data Handler
>>> timecode : 00:00:03:00
>>> Stream mapping:
>>> Stream #0:0 -> #0:0 (prores -> libx264)
>>> Stream #0:1 -> #0:1 (pcm_s16le -> libfdk_aac)
>>> Press [q] to stop, [?] for help
>>> frame= 8200 fps= 15 q=-1.0 Lsize= 66450kB time=00:05:42.01 bitrate=1591.6kbits/s
>>> video:60883kB audio:5345kB subtitle:0 global headers:0kB muxing overhead 0.335523%
>>> [libx264 @ 0x7ffb41809a00] frame I:62 Avg QP:15.59 size: 76674
>>> [libx264 @ 0x7ffb41809a00] frame P:1804 Avg QP:18.77 size: 17581
>>> [libx264 @ 0x7ffb41809a00] frame B:6334 Avg QP:22.65 size: 4085
>>> [libx264 @ 0x7ffb41809a00] consecutive B-frames: 1.4% 2.0% 7.1% 36.5% 13.2% 30.1% 3.1% 1.8% 4.8%
>>> [libx264 @ 0x7ffb41809a00] mb I I16..4: 13.1% 68.8% 18.1%
>>> [libx264 @ 0x7ffb41809a00] mb P I16..4: 1.3% 5.3% 0.7% P16..4: 42.2% 12.6% 12.0% 0.3% 0.1% skip:25.6%
>>> [libx264 @ 0x7ffb41809a00] mb B I16..4: 0.0% 0.4% 0.1% B16..8: 34.7% 4.1% 0.9% direct: 1.9% skip:57.9% L0:44.1% L1:50.0% BI: 5.9%
>>> [libx264 @ 0x7ffb41809a00] 8x8 transform intra:72.3% inter:71.1%
>>> [libx264 @ 0x7ffb41809a00] direct mvs spatial:98.8% temporal:1.2%
>>> [libx264 @ 0x7ffb41809a00] coded y,uvDC,uvAC intra: 72.7% 57.0% 23.5% inter: 8.6% 6.4% 0.3%
>>> [libx264 @ 0x7ffb41809a00] i16 v,h,dc,p: 30% 16% 6% 48%
>>> [libx264 @ 0x7ffb41809a00] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 14% 8% 6% 9% 12% 13% 12% 13% 12%
>>> [libx264 @ 0x7ffb41809a00] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 14% 8% 2% 10% 15% 14% 13% 11% 11%
>>> [libx264 @ 0x7ffb41809a00] i8c dc,h,v,p: 26% 34% 22% 17%
>>> [libx264 @ 0x7ffb41809a00] Weighted P-Frames: Y:5.5% UV:3.8%
>>> [libx264 @ 0x7ffb41809a00] ref P L0: 50.0% 10.9% 14.2% 4.9% 4.1% 3.3% 2.8% 1.4% 1.3% 1.2% 1.1% 1.0% 1.0% 1.0% 1.0% 0.7%
>>> [libx264 @ 0x7ffb41809a00] ref B L0: 79.7% 8.0% 4.0% 1.7% 1.4% 1.2% 1.0% 0.5% 0.5% 0.4% 0.4% 0.4% 0.4% 0.3% 0.2%
>>> [libx264 @ 0x7ffb41809a00] ref B L1: 93.3% 6.7%
>>> [libx264 @ 0x7ffb41809a00] kb/s:1458.30
>>>
>>>
>>> _______________________________________________
>>> ffmpeg-user mailing list
>>> ffmpeg-user at ffmpeg.org
>>> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>> _______________________________________________
>> ffmpeg-user mailing list
>> ffmpeg-user at ffmpeg.org
>> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
More information about the ffmpeg-user
mailing list