GSoC 2009: implementing multiple quality levels in resamplers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



RE: implementing multiple quality levels.

At this point, it would appear to me that the simplest way would be to
put all the nohalo levels and snohalo levels in one single file, and
toggle between them based on requested quality level (determines the
level used) and blur level (if blur <= 0, use nohalo, if blur >0, use
snohalo).

What I don't see right now is this:

1) Although this has the advantage of "putting all the nohalo/snohalo
stuff in one place," I wonder if toggling between methods at the
sampler level will have a large speed hit. Keeping things separate,
although it would force the calling operation to specifically request
a particular version of the scheme, may lead to faster operation.

2) The current gegl implementation of nohalo level 1
(gegl/gegl/buffer/gegl-sampler-sharp.c) contains the following code:

static void
gegl_sampler_sharp_init (GeglSamplerSharp *self)
{
  /*
   * context_rect is a five-by-five stencil centered around the
   * nearest input pixel center. See comment below about using a
   * "non-centered" stencil (one based at the corner) instead.
   */
  GEGL_SAMPLER (self)->context_rect.x = -2;
  GEGL_SAMPLER (self)->context_rect.y = -2;
  GEGL_SAMPLER (self)->context_rect.width = 5;
  GEGL_SAMPLER (self)->context_rect.height = 5;
  GEGL_SAMPLER (self)->interpolate_format = babl_format ("RaGaBaA float");
}

Basically, this code specifies the "footprint" (stencil) of the input
image data needed by the resampler.

The issue is this:

snohalo level 1, for example, has a different footprint than nohalo
level 1, and both are different from the footprints of snohalo level
2.

I've given Eric the job of figuring out how to intelligently switch
between methods/footprints based on requested quality and blur
levels. However, if you have any idea/suggestion, please let us know.

Nicolas Robidoux
Universite Laurentienne
_______________________________________________
Gegl-developer mailing list
Gegl-developer@xxxxxxxxxxxxxxxxxxxxxx
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gegl-developer

[Index of Archives]     [Yosemite News]     [Yosemite Photos]     [gtk]     [GIMP Users]     [KDE]     [Gimp's Home]     [Gimp on Windows]     [Steve's Art]

  Powered by Linux