Re: [GD-DEVEL] Gaussian Blur

[email protected] (Chris Barker) Thu, 5 Dec 2013 17:02:31 -0800
Newsgroups php.gd.devel
Message-ID <CALGmxE+qxtD0h6ha91euTz_jP81gZpuwWW-E0q-bLccrt4hygQ@mail.gmail.com>
--001a1132e8e4c573f904ecd335de
Content-Type: text/plain; charset=UTF-8

On Thu, Dec 5, 2013 at 3:53 PM, Chris Reuter <[email protected]> wrote:

> On Thu, Dec 05, 2013 at 03:15:27PM -0800, Chris Barker wrote:
> Just FYI, some of the scaling code already does this.  I suppose we
> ought to track down where it does this and ensure that it doesn't
> modify the source image.
>
> to be fair, I've only really looked at the rendering code so far -- not
image processing stuff. So if there is a precedent for much of that already
returning truecolor images, then maybe this isn't a problem. A lot of that
really doesn't work well with palletted images anyway.

> One could argue that running a gaussian blur on a palletted image is let
> > than ideal anyway (and you'd be right), but if the existing API supports
> it
> > it'd be better not to change that.
> >
> > Could your code switch on the image type an cal the old routing for
> > palleted images?
>
> The easiest thing would be to just leave in the old GB and add mine as
> an additional thing.
>
> There's a matrix convolution function that a bunch of functions wrap
> to do various filtery things, one of them being Gaussian blur.
> Changing it to use mine would actually increase the code size.
>
> However, it also means that there are now two different unrelated
> Gaussian blur functions and that kind of grates on me.  I was hoping
> to unify it.
>

I agree -- it would be cleaner.


> Oh well.  The real world wreaks all kinds of havoc on my code.  I'll
> leave the old GB alone.


don't necessarily do it this way on my account -- I'm only one guy...

Is there a "deprecation" policy for gd? maybe the old one should be
deprecated and removed a few releases later...

-Chris



-- 

Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

[email protected]

--001a1132e8e4c573f904ecd335de--