[Gegl-developer] in-place buffers

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

 



As for a scheme, would it be worthwhile to simply set a property (like "in-place") of the ImageData object to true or false, and then insist that every Op know how to deal with objects where the destination may overlap with the source?

Op's could check the value of "in-place" if they need to compensate for overlapping buffers (like my implementation of Copy, which would be a null op for in-place buffers, though Fade, I have noticed would need no change).

For binary ops, you could insist that only one Image be operated on in place, or assume the left one is in-place if they both try to be. However, if the code is overlap safe, you could take care of the overlapping regions in the instantiation init code, simply setting destination to the correct input.

You could, in fact, even use copy in order to create a new buffer to operate on in place from that point forward.

--
Daniel S. Rogers


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

  Powered by Linux