[FFmpeg-trac] #8509(avcodec:new): Converting 8 bit ARGB to Prores 4444 using prores_ks produces alpha channel that is not 100%
FFmpeg
trac at avcodec.org
Mon Feb 3 21:13:08 EET 2020
#8509: Converting 8 bit ARGB to Prores 4444 using prores_ks produces alpha channel
that is not 100%
-----------------------------------+----------------------------------
Reporter: bford | Type: defect
Status: new | Priority: normal
Component: avcodec | Version: 4.2
Keywords: prores_ks | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
-----------------------------------+----------------------------------
I am using ffmpeg to convert an 8bit ARGB source to Prores 4444 mov.
Anywhere the alpha is 255 in the source; the output alpha when loading the
resulting MOV file into after effects, the alpha comes out as 254 and has
slight transparency. The RGB channels are all correctly 255.
Command Line:
ffmpeg -y -i "Viewport.tga" -c:v prores_ks -pix_fmt yuva444p10le
-profile:v 4444 -alpha_bits 16 "Prores444.mov"
I will attach the input TGA file and can attach the output prores file
also.
I've tested with both TGA input files, and RAW, so I know the issue is not
with the input; it is something in the Prores output.
Using QTRLE for an output codec works fine; all alpha channel values are
correct.
----
FFMPEG Output:
ffmpeg started on 2020-02-03 at 13:51:49
Report written to "ffmpeg-20200203-135149.log"
Log level: 48
Command line:
ffmpeg -y -i "d:\\TempProjects\\Viewport.tga" -c:v prores_ks -pix_fmt
yuva444p10le -profile:v 4444 -alpha_bits 16
"d:\\tempprojects\\Prores444.mov" -report
ffmpeg version git-2020-02-03-1c15111 Copyright (c) 2000-2020 the FFmpeg
developers
built with gcc 9.2.1 (GCC) 20200122
configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-
fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-
libdav1d --enable-libbluray --enable-libfreetype --enable-libmp3lame
--enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg
--enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr
--enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack
--enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2
--enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-
libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa
--enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx
--enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-nvenc
--enable-nvdec --enable-dxva2 --enable-avisynth --enable-libopenmpt
--enable-amf
libavutil 56. 38.100 / 56. 38.100
libavcodec 58. 67.100 / 58. 67.100
libavformat 58. 37.100 / 58. 37.100
libavdevice 58. 9.103 / 58. 9.103
libavfilter 7. 73.100 / 7. 73.100
libswscale 5. 6.100 / 5. 6.100
libswresample 3. 6.100 / 3. 6.100
libpostproc 55. 6.100 / 55. 6.100
Splitting the commandline.
Reading option '-y' ... matched as option 'y' (overwrite output files)
with argument '1'.
Reading option '-i' ... matched as input url with argument
'd:\TempProjects\Viewport.tga'.
Reading option '-c:v' ... matched as option 'c' (codec name) with argument
'prores_ks'.
Reading option '-pix_fmt' ... matched as option 'pix_fmt' (set pixel
format) with argument 'yuva444p10le'.
Reading option '-profile:v' ... matched as option 'profile' (set profile)
with argument '4444'.
Reading option '-alpha_bits' ... matched as AVOption 'alpha_bits' with
argument '16'.
Reading option 'd:\tempprojects\Prores444.mov' ... matched as output url.
Reading option '-report' ... matched as option 'report' (generate a
report) with argument '1'.
Finished splitting the commandline.
Parsing a group of options: global .
Applying option y (overwrite output files) with argument 1.
Applying option report (generate a report) with argument 1.
Successfully parsed a group of options.
Parsing a group of options: input url d:\TempProjects\Viewport.tga.
Successfully parsed a group of options.
Opening an input file: d:\TempProjects\Viewport.tga.
[NULL @ 0000026ca402ca80] Opening 'd:\TempProjects\Viewport.tga' for
reading
[file @ 0000026ca402da00] Setting default whitelist 'file,crypto,data'
[image2 @ 0000026ca402ca80] Format image2 probed with size=2048 and
score=50
[image2 @ 0000026ca402ca80] Before avformat_find_stream_info() pos: 0
bytes read:32768 seeks:0 nb_streams:1
[image2 @ 0000026ca402ca80] After avformat_find_stream_info() pos: 87738
bytes read:87738 seeks:0 frames:1
Input #0, image2, from 'd:\TempProjects\Viewport.tga':
Duration: 00:00:00.04, start: 0.000000, bitrate: 17547 kb/s
Stream #0:0, 1, 1/25: Video: targa, bgra, 1920x1080, 25 tbr, 25 tbn,
25 tbc
Successfully opened the file.
Parsing a group of options: output url d:\tempprojects\Prores444.mov.
Applying option c:v (codec name) with argument prores_ks.
Applying option pix_fmt (set pixel format) with argument yuva444p10le.
Applying option profile:v (set profile) with argument 4444.
Successfully parsed a group of options.
Opening an output file: d:\tempprojects\Prores444.mov.
[file @ 0000026ca403d240] Setting default whitelist 'file,crypto,data'
Successfully opened the file.
Stream mapping:
Stream #0:0 -> #0:0 (targa (native) -> prores (prores_ks))
Press [q] to stop, [?] for help
cur_dts is invalid st:0 (0) [init:0 i_done:0 finish:0] (this is harmless
if it occurs once at the start per stream)
detected 12 logical cores
[graph 0 input from stream 0:0 @ 0000026ca403d880] Setting 'video_size' to
value '1920x1080'
[graph 0 input from stream 0:0 @ 0000026ca403d880] Setting 'pix_fmt' to
value '28'
[graph 0 input from stream 0:0 @ 0000026ca403d880] Setting 'time_base' to
value '1/25'
[graph 0 input from stream 0:0 @ 0000026ca403d880] Setting 'pixel_aspect'
to value '0/1'
[graph 0 input from stream 0:0 @ 0000026ca403d880] Setting 'frame_rate' to
value '25/1'
[graph 0 input from stream 0:0 @ 0000026ca403d880] w:1920 h:1080
pixfmt:bgra tb:1/25 fr:25/1 sar:0/1
[format @ 0000026ca4098c40] Setting 'pix_fmts' to value 'yuva444p10le'
[auto_scaler_0 @ 0000026ca4099200] Setting 'flags' to value 'bicubic'
[auto_scaler_0 @ 0000026ca4099200] w:iw h:ih flags:'bicubic' interl:0
[format @ 0000026ca4098c40] auto-inserting filter 'auto_scaler_0' between
the filter 'Parsed_null_0' and the filter 'format'
[AVFilterGraph @ 0000026ca4096ec0] query_formats: 4 queried, 2 merged, 1
already done, 0 delayed
[auto_scaler_0 @ 0000026ca4099200] w:1920 h:1080 fmt:bgra sar:0/1 ->
w:1920 h:1080 fmt:yuva444p10le sar:0/1 flags:0x4
[prores_ks @ 0000026ca40c1940] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca40c1940] frame size upper bound: 33813678
[prores_ks @ 0000026ca404fcc0] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca404fcc0] frame size upper bound: 33813678
[prores_ks @ 0000026ca4911f00] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca4911f00] frame size upper bound: 33813678
[prores_ks @ 0000026ca491db80] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca491db80] frame size upper bound: 33813678
[prores_ks @ 0000026ca4929800] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca4929800] frame size upper bound: 33813678
[prores_ks @ 0000026ca4935680] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca4935680] frame size upper bound: 33813678
[prores_ks @ 0000026ca4947d00] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca4947d00] frame size upper bound: 33813678
[prores_ks @ 0000026ca4953b80] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca4953b80] frame size upper bound: 33813678
[prores_ks @ 0000026ca495fa00] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca495fa00] frame size upper bound: 33813678
[prores_ks @ 0000026ca496b840] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca496b840] frame size upper bound: 33813678
[prores_ks @ 0000026ca4978600] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca4978600] frame size upper bound: 33813678
[prores_ks @ 0000026ca4984d40] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca4984d40] frame size upper bound: 33813678
[prores_ks @ 0000026ca4037240] profile 4, 1020 slices, interlacing: no,
28500 bits per MB
[prores_ks @ 0000026ca4037240] frame size upper bound: 33813678
Output #0, mov, to 'd:\tempprojects\Prores444.mov':
Metadata:
encoder : Lavf58.37.100
Stream #0:0, 0, 1/12800: Video: prores (prores_ks) (ap4h /
0x68347061), yuva444p10le, 1920x1080, q=2-31, 200 kb/s, 25 fps, 12800 tbn,
25 tbc
Metadata:
encoder : Lavc58.67.100 prores_ks
Clipping frame in rate conversion by 0.000008
cur_dts is invalid st:0 (0) [init:1 i_done:0 finish:0] (this is harmless
if it occurs once at the start per stream)
cur_dts is invalid st:0 (0) [init:1 i_done:0 finish:0] (this is harmless
if it occurs once at the start per stream)
[out_0_0 @ 0000026ca4098a80] EOF on sink link out_0_0:default.
No more output streams to write to, finishing.
frame= 1 fps=0.0 q=-0.0 Lsize= 50kB time=00:00:00.00
bitrate=5273025.6kbits/s speed=0.000222x
video:49kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB
muxing overhead: 1.432348%
Input file #0 (d:\TempProjects\Viewport.tga):
Input stream #0:0 (video): 1 packets read (87738 bytes); 1 frames
decoded;
Total: 1 packets (87738 bytes) demuxed
Output file #0 (d:\tempprojects\Prores444.mov):
Output stream #0:0 (video): 1 frames encoded; 1 packets muxed (50686
bytes);
Total: 1 packets (50686 bytes) muxed
1 frames successfully decoded, 0 decoding errors
[AVIOContext @ 0000026ca4096040] Statistics: 2 seeks, 4 writeouts
[AVIOContext @ 0000026ca4035c80] Statistics: 87738 bytes read, 0 seeks
--
Ticket URL: <https://trac.ffmpeg.org/ticket/8509>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list