Diffusion Krita f80c0940d1e1

Fix calculations of source rectangle and selection dimensions when sending data…

Authored by nicholasl on Jul 13 2017, 1:12 AM.

Description

Fix calculations of source rectangle and selection dimensions when sending data to G'MIC

When there was no selection, the old plug-in would read and write pixels within the rectangle (0,0 canvasWidth x canvasHeight).
The new plug-in was still set up to do this, except it would send the rectangle (0,0 layerWidth x layerHeight) to G'MIC.

When there was a selection in the old plug-in, it would read and write within the selection rectangle.
The new plug-in would read using (0,0 layerWidth x layerHeight), then write inside the selection rectangle.

This commit should reinstate the old behavior.

BUG:381732
Differential Revision: https://phabricator.kde.org/D6431