app: don't modify paint buffer when pasting to canvas
We now have enough machinery in gimppaintcore-loops to avoid modifying the paint buffer in gimp_paint_core_paste() in the no- applicator case, by using the same set of algorithms as gimp_paint_core_replace(). Other than reducing the number of different code paths we have, this is both more efficient, and allows us to reuse the paint buffer across dabs, as done in the following commits. Implement gimp_paint_core_replace() in terms of gimp_paint_core_paste(). We keep the two functions separate, since their implementation is still differnet when using an applicator. Suppress the paint-buffer-modifying algorithms in gimppaintcore-loops, but keep them around; using the same logic for normal painting as we use for REPLACE painting is possible due to the fact that all our current non-REPLACE modes treat alpha values and mask values interchangeably. In the future we might have modes that distinguish between alpha and mask values, requiring the old algorithms.
Showing with 14 additions and 76 deletions