Re: [FFmpeg-devel] [PATCH] lavfi/paletteuse: fix to support transparency

2017-11-02 Thread Bjorn Roche
On Sat, Oct 28, 2017 at 11:18 AM, Clément Bœsch  wrote:

> On Mon, Oct 23, 2017 at 07:12:57PM -0400, Bjorn Roche wrote:
> > This patch enables paletteuse to identify the transparency in incoming
> > video and tag transparent pixels on outgoing video with the correct
> > index from the palette.
> >
> > This requires tracking the transparency index in the palette,
> > establishing an alpha threshold below which a pixel is considered
> > transparent and above which the pixel is considered opaque, and
> > additional changes to track the alpha value throughout the conversion
> > process.
> >
> > This change is a partial fix for https://trac.ffmpeg.org/ticket/4443
> > However, animated GIFs are still output incorrectly due to a bug
> > in gif optimization which does not correctly handle transparency.
> > ---
> >  doc/filters.texi|   7 ++
> >  libavfilter/vf_paletteuse.c | 195 --
> --
>
> patch applied. I took the liberty to make the following changes before
> pushing:
>
> - fix spacing issues around () you forgot to fix
>

Sorry. It's the exact opposite of how I usually do it, so I can't even see
it :(


> - rename "threshold" into "alpha_threshold"
>

Much better.


> - move the option documentation in the appropriate place (it was between
>   diff_mode and one of its constant)
>

Cool. Thanks.


>
> Thanks for the patch, and sorry about the delay.
>

Thanks for everyone's help and feedback!

bjorn

-- 


Bjorn Roche

Sr. Video Pipeline Engineer

bj...@giphy.com
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] lavfi/paletteuse: fix to support transparency

2017-10-28 Thread Clément Bœsch
On Mon, Oct 23, 2017 at 07:12:57PM -0400, Bjorn Roche wrote:
> This patch enables paletteuse to identify the transparency in incoming
> video and tag transparent pixels on outgoing video with the correct
> index from the palette.
> 
> This requires tracking the transparency index in the palette,
> establishing an alpha threshold below which a pixel is considered
> transparent and above which the pixel is considered opaque, and
> additional changes to track the alpha value throughout the conversion
> process.
> 
> This change is a partial fix for https://trac.ffmpeg.org/ticket/4443
> However, animated GIFs are still output incorrectly due to a bug
> in gif optimization which does not correctly handle transparency.
> ---
>  doc/filters.texi|   7 ++
>  libavfilter/vf_paletteuse.c | 195 
> 

patch applied. I took the liberty to make the following changes before
pushing:

- fix spacing issues around () you forgot to fix
- rename "threshold" into "alpha_threshold"
- move the option documentation in the appropriate place (it was between
  diff_mode and one of its constant)

Thanks for the patch, and sorry about the delay.

Regards,

-- 
Clément B.


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel