[FFmpeg-devel] [misc-filters PATCH 2/5] Add color source.

Stefano Sabatini stefano.sabatini-lala
Fri Jul 16 18:58:13 CEST 2010


On date Friday 2010-07-02 00:25:56 +0200, Michael Niedermayer encoded:
> On Thu, Jul 01, 2010 at 11:12:02PM +0200, Stefano Sabatini wrote:
> > On date Thursday 2010-07-01 13:26:07 +0200, Michael Niedermayer encoded:
> > > On Wed, Jun 30, 2010 at 01:42:12AM +0200, Stefano Sabatini wrote:
> > > [...]
> > > > +static int color_config_props(AVFilterLink *inlink)
> > > > +{
> > > > +    AVFilterContext *ctx = inlink->src;
> > > > +    ColorContext *priv = ctx->priv;
> > > > +    uint8_t rgba_color[4];
> > > > +    uint8_t rgba_map[4];
> > > > +    int i, is_packed_rgb = 1;
> > > > +    const AVPixFmtDescriptor *pix_desc = &av_pix_fmt_descriptors[inlink->format];
> > > > +
> > > > +    switch (inlink->format) {
> > > > +    case PIX_FMT_ARGB:
> > > > +        rgba_map[ALPHA] = 0; rgba_map[RED] = 1; rgba_map[GREEN] = 2; rgba_map[BLUE] = 3;
> > > > +        break;
> > > > +    case PIX_FMT_ABGR:
> > > > +        rgba_map[ALPHA] = 0; rgba_map[BLUE] = 1; rgba_map[GREEN] = 2; rgba_map[RED] = 3;
> > > > +        break;
> > > > +    case PIX_FMT_RGBA:
> > > > +    case PIX_FMT_RGB24:
> > > > +        rgba_map[RED] = 0; rgba_map[GREEN] = 1; rgba_map[BLUE] = 2; rgba_map[ALPHA] = 3;
> > > > +        break;
> > > > +    case PIX_FMT_BGRA:
> > > > +    case PIX_FMT_BGR24:
> > > > +        rgba_map[BLUE] = 0; rgba_map[GREEN] = 1; rgba_map[RED] = 2; rgba_map[ALPHA] = 3;
> > > > +        break;
> > > > +    default:
> > > > +        is_packed_rgb = 0;
> > > > +    }
> > > 
> > > looks like a duplicate
> > 
> > Updated, depends on the refactoring patches just posted. Also
> > documentation added.
> > 
> > Regards.
> > -- 
> > FFmpeg = Free and Faithful Multipurpose Ponderous Elfic Gorilla
> 
> >  doc/filters.texi         |   39 ++++++++++++++
> >  libavfilter/Makefile     |    1 
> >  libavfilter/allfilters.c |    1 
> >  libavfilter/vf_pad.c     |  125 +++++++++++++++++++++++++++++++++++++++++++++++
> >  4 files changed, 166 insertions(+)
> > 7ebf4888c4fa1845bcb663832721137b3e78833b  0006-Add-color-source.patch
> > >From b0c9468960edea2df372da8391ca97cd0173e32b Mon Sep 17 00:00:00 2001
> > Message-Id: <b0c9468960edea2df372da8391ca97cd0173e32b.1278018672.git.stefano.sabatini-lala at poste.it>
> > In-Reply-To: <3885a095f4b884324123fe5cc8a8a1bf28968407.1278018672.git.stefano.sabatini-lala at poste.it>
> > References: <3885a095f4b884324123fe5cc8a8a1bf28968407.1278018672.git.stefano.sabatini-lala at poste.it>
> > From: Stefano Sabatini <stefano.sabatini-lala at poste.it>
> > Date: Thu, 1 Jul 2010 21:51:44 +0200
> > Subject: [misc-filters PATCH 6/8] Add color source.
> > 
> > ---
> >  doc/filters.texi         |   39 ++++++++++++++
> >  libavfilter/Makefile     |    1 +
> >  libavfilter/allfilters.c |    1 +
> >  libavfilter/vf_pad.c     |  125 ++++++++++++++++++++++++++++++++++++++++++++++
> >  4 files changed, 166 insertions(+), 0 deletions(-)
> > 
> > diff --git a/doc/filters.texi b/doc/filters.texi
> > index c6b9161..e3c1163 100644
> > --- a/doc/filters.texi
> > +++ b/doc/filters.texi
> 

> add yourself to maintainers for Documentation
> you arent the best englishman but you are the best that is actively working
> toward extending the documentation

I'll do that. In practice that will no have many consequences, I'll
post patches whenever I'm not sure about my English.
 
> the rest of the patch looks fine

I'm reposting this patch. Note that it is adding a dependency on lavc
av_parse_(), that's not issue for now as we already depends on that
and I want to fix once and for all the problem by introducing
libavcore.

Regards.



More information about the ffmpeg-devel mailing list