[FFmpeg-trac] #4444(swscale:new): Transparency gets lost when scaling pal8
FFmpeg
trac at avcodec.org
Mon Dec 16 14:32:25 EET 2024
#4444: Transparency gets lost when scaling pal8
-------------------------------------+-------------------------------------
Reporter: Carl Eugen | Owner: (none)
Hoyos |
Type: defect | Status: new
Priority: normal | Component: swscale
Version: git-master | Resolution:
Keywords: pal8 alpha | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
-------------------------------------+-------------------------------------
Comment (by Niklas Haas):
So, the fundamental problem here is that swscale does not support "true"
PAL8 output. Instead a hack is performed by converting instead to BGR8 and
then just tagging that as PAL8 (using avpriv_set_systematic_pal2).
The proper handling of paletted output would require generating a suitable
palette and then dithering the image using that set of colors. (See
vf_palettegen/paletteuse)
With the new graph dispatch infrastructure, it would be fairly
straightforward to incorporate those filters as extra output passes,
although it will require moving some code around. However, I propose
simply dropping the "systematic" PAL8 output hack for now, at least in the
case of inputs with an alpha channel.
--
Ticket URL: <https://trac.ffmpeg.org/ticket/4444#comment:1>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list