[FFmpeg-user] White Padding Looks Gray

Morgan Bellinger mbellinger at stitchfix.com
Fri Jun 10 19:22:12 CEST 2016


I'm an ffmpeg beginner experiencing an issue with adding white padding to a
video straight out of a 5D Mark III. Our workflow is to capture via EOS
Utility and a tethered camera, which yields a MOV file (a.MOV) - I'd then
like to rotate that file and center it in a square frame with white
padding. I don't need any audio.

Whenever I run this command, however, I get a light gray instead of white
in the padding area.

It's quite similar to this situation:
http://video.stackexchange.com/questions/16682/ffmpeg-white-padding-is-light-grey-but-not-white
- but in my case, I need a video output, not stills.

*command:*

ffmpeg -i a.MOV -codec:v libx264 -profile:v high -preset slow -b:v 500k
-maxrate 500k -bufsize 1000k -vf
"transpose=2,pad=1920:1920:420:color=White" -threads 0 -an k.mp4

*console:*

ffmpeg version 3.0.2 Copyright (c) 2000-2016 the FFmpeg developers

  built with Apple LLVM version 7.3.0 (clang-703.0.29)

  configuration: --prefix=/usr/local/Cellar/ffmpeg/3.0.2 --enable-shared
--enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables
--enable-avresample --cc=clang --host-cflags= --host-ldflags=
--enable-opencl --enable-libx264 --enable-libmp3lame --enable-libxvid
--enable-vda

  libavutil      55. 17.103 / 55. 17.103

  libavcodec     57. 24.102 / 57. 24.102

  libavformat    57. 25.100 / 57. 25.100

  libavdevice    57.  0.101 / 57.  0.101

  libavfilter     6. 31.100 /  6. 31.100

  libavresample   3.  0.  0 /  3.  0.  0

  libswscale      4.  0.100 /  4.  0.100

  libswresample   2.  0.101 /  2.  0.101

  libpostproc    54.  0.100 / 54.  0.100

Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'a.MOV':

  Metadata:

    major_brand     : qt

    minor_version   : 537331968

    compatible_brands: qt  CAEP

    com.apple.quicktime.make: Canon

    com.apple.quicktime.model: Canon EOS 5D Mark III

    com.apple.quicktime.rating.user: 0.000000

    com.apple.quicktime.copyright: Figure 1 Video

    com.apple.quicktime.author: Figure 1 Video

    creation_time   : 2016-06-09 12:03:30

  Duration: 00:00:07.41, start: 0.000000, bitrate: 18988 kb/s

    Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuvj420p(pc,
bt709), 1920x1080 [SAR 1:1 DAR 16:9], 17343 kb/s, 29.97 fps, 29.97 tbr, 30k
tbn, 60k tbc (default)

    Metadata:

      creation_time   : 2016-06-09 12:03:30

      timecode        : 05:27:00;20

    Stream #0:1(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz,
stereo, s16, 1536 kb/s (default)

    Metadata:

      creation_time   : 2016-06-09 12:03:30

      timecode        : 05:27:00;20

    Stream #0:2(eng): Data: none (tmcd / 0x64636D74), 0 kb/s (default)

    Metadata:

      creation_time   : 2016-06-09 12:03:30

      timecode        : 05:27:00;20

No pixel format specified, yuvj420p for H.264 encoding chosen.

Use -pix_fmt yuv420p for compatibility with outdated media players.

[libx264 @ 0x7fefbb00f400] using SAR=1/1

[libx264 @ 0x7fefbb00f400] using cpu capabilities: MMX2 SSE2Fast SSSE3
SSE4.2 AVX FMA3 AVX2 LZCNT BMI2

[libx264 @ 0x7fefbb00f400] profile High, level 5.0

[libx264 @ 0x7fefbb00f400] 264 - core 148 r2668 fd2c324 - H.264/MPEG-4 AVC
codec - Copyleft 2003-2016 - http://www.videolan.org/x264.html - options:
cabac=1 ref=5 deblock=1:0:0 analyse=0x3:0x113 me=umh subme=8 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=2
b_bias=0 direct=3 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=25
scenecut=40 intra_refresh=0 rc_lookahead=50 rc=cbr mbtree=1 bitrate=500
ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 vbv_maxrate=500
vbv_bufsize=1000 nal_hrd=none filler=0 ip_ratio=1.40 aq=1:1.00

Output #0, mp4, to 'k.mp4':

  Metadata:

    major_brand     : qt

    minor_version   : 537331968

    compatible_brands: qt  CAEP

    com.apple.quicktime.make: Canon

    com.apple.quicktime.model: Canon EOS 5D Mark III

    com.apple.quicktime.rating.user: 0.000000

    com.apple.quicktime.copyright: Figure 1 Video

    com.apple.quicktime.author: Figure 1 Video

    encoder         : Lavf57.25.100

    Stream #0:0(eng): Video: h264 (libx264) ([33][0][0][0] / 0x0021),
yuvj420p(pc), 1920x1920 [SAR 1:1 DAR 1:1], q=-1--1, 500 kb/s, 29.97 fps,
30k tbn, 29.97 tbc (default)

    Metadata:

      creation_time   : 2016-06-09 12:03:30

      timecode        : 05:27:00;20

      encoder         : Lavc57.24.102 libx264

    Side data:

      unknown side data type 10 (24 bytes)

Stream mapping:

  Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))

Press [q] to stop, [?] for help

[h264 @ 0x7fefbb5b7000] Increasing reorder buffer to 1

frame=   57 fps= 33 q=0.0 size=       0kB time=00:00:00.00 bitrate=N/A
dup=2 droframe=   72 fps= 31 q=43.0 size=      22kB time=00:00:00.33
bitrate= 529.2kbits/frame=   86 fps= 31 q=42.0 size=      51kB
time=00:00:00.80 bitrate= 521.9kbits/frame=  102 fps= 30 q=41.0 size=
72kB time=00:00:01.33 bitrate= 442.1kbits/frame=  118 fps= 30 q=41.0 size=
    97kB time=00:00:01.86 bitrate= 426.3kbits/frame=  133 fps= 29 q=42.0
size=     123kB time=00:00:02.36 bitrate= 425.8kbits/frame=  149 fps= 29
q=43.0 size=     159kB time=00:00:02.90 bitrate= 448.3kbits/frame=  164
fps= 29 q=40.0 size=     182kB time=00:00:03.40 bitrate= 437.9kbits/frame=
181 fps= 29 q=41.0 size=     212kB time=00:00:03.97 bitrate=
437.9kbits/frame=  196 fps= 29 q=42.0 size=     241kB time=00:00:04.47
bitrate= 440.9kbits/frame=  212 fps= 29 q=42.0 size=     275kB
time=00:00:05.00 bitrate= 449.5kbits/frame=  222 fps= 27 q=-1.0 Lsize=
379kB time=00:00:07.34 bitrate= 423.0kbits/s dup=2 drop=0 speed=0.879x

video:376kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB
muxing overhead: 0.880310%

[libx264 @ 0x7fefbb00f400] frame I:1     Avg QP:31.59  size: 10720

[libx264 @ 0x7fefbb00f400] frame P:63    Avg QP:30.84  size:  3633

[libx264 @ 0x7fefbb00f400] frame B:158   Avg QP:38.24  size:   914

[libx264 @ 0x7fefbb00f400] consecutive B-frames:  1.4%  5.4% 17.6% 75.7%

[libx264 @ 0x7fefbb00f400] mb I  I16..4:  6.7% 92.3%  1.0%

[libx264 @ 0x7fefbb00f400] mb P  I16..4:  1.0%  1.4%  0.0%  P16..4:  4.6%
0.9%  0.3%  0.0%  0.0%    skip:91.7%

[libx264 @ 0x7fefbb00f400] mb B  I16..4:  0.0%  0.0%  0.0%  B16..8:  3.4%
0.1%  0.0%  direct: 0.0%  skip:96.4%  L0:39.0% L1:59.3% BI: 1.6%

[libx264 @ 0x7fefbb00f400] 8x8 transform intra:70.8% inter:89.5%

[libx264 @ 0x7fefbb00f400] direct mvs  spatial:98.1% temporal:1.9%

[libx264 @ 0x7fefbb00f400] coded y,uvDC,uvAC intra: 10.2% 11.1% 0.4% inter:
0.5% 0.1% 0.0%

[libx264 @ 0x7fefbb00f400] i16 v,h,dc,p: 40% 37%  5% 18%

[libx264 @ 0x7fefbb00f400] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 31% 14% 43%  2%
2%  3%  2%  2%  2%

[libx264 @ 0x7fefbb00f400] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 22% 12%  9% 10%
12% 12%  9%  7%  7%

[libx264 @ 0x7fefbb00f400] i8c dc,h,v,p: 79% 13%  7%  1%

[libx264 @ 0x7fefbb00f400] Weighted P-Frames: Y:0.0% UV:0.0%

[libx264 @ 0x7fefbb00f400] ref P L0: 71.1%  4.6% 16.1%  3.7%  4.4%  0.1%

[libx264 @ 0x7fefbb00f400] ref B L0: 89.7%  7.9%  1.8%  0.6%

[libx264 @ 0x7fefbb00f400] ref B L1: 98.1%  1.9%

[libx264 @ 0x7fefbb00f400] kb/s:414.71


More information about the ffmpeg-user mailing list