On Wed, Jul 1, 2009 at 9:19 PM, Adam Turcotte<adam.turcotte@xxxxxxxxx> wrote: > I will be implementing Nohalo Level 2 for GEGL. This basically > involves computing double-density pixel data (with a specialized > version of Nohalo Level 1 minus the finishing bilinear) and then > running a slightly modified version of Nohalo Level 1. The simplest > way of implementing this is by having a small "persistent" array or > buffer storing double-density pixel data locally so that the required > values from Level 1 are not recomputed over and over. > > I originally thought that I could simply use GeglBuffers for this > purpose, but the GeglBuffer code seems fairly complicated. Instead, I > believe that small static arrays could be a better choice. For > example, a 64x64 double-density data array can be computed with the > buffer data corresponding to a context_rect/fetch_rectangle of size > 35x35. When the currently stored static array does not contain the > Level 1 data needed to compute the Level 2 value at the current > location, it would simply be recomputed, much like they are in > gegl_sampler_get_ptr (in gegl-sampler.c). It sounds like a reasonable approach it might be better if this buffer is allocated on the heap and allocated/freed by the sampler. /Øyvind K. -- «The future is already here. It's just not very evenly distributed» -- William Gibson http://pippin.gimp.org/ http://ffii.org/ _______________________________________________ Gegl-developer mailing list Gegl-developer@xxxxxxxxxxxxxxxxxxxxxx https://lists.XCF.Berkeley.EDU/mailman/listinfo/gegl-developer