Spot white balance does not work correctly on cropped image
When working with the spot white balance tool, if you crop the image then the spot white balance tool will only work on an area of the image in the top left corner that corresponds to the size of the crop. The spot white balance tool therefore only works correctly if the crop is applied in the top left corner. If the cropped area does not overlap with a rectangle of the same size centred on the top left corner then the spot white balance does not work at all.
To replicate bug:
- Open any file in darkroom mode
- Crop the image to the top left 1/4 of the image, and apply the crop.
- Note that the spot white balance tool works as expected
- Move the cropped area to the top right quadrant of the image.
- Note that the spot white balance tool does not work at all.
- Move the cropped area to the top middle of the image.
- Note that the spot white balance tool only works in the left half of the cropped area.
I discovered this bug while working on my most recent darktable tutorial video, so you can see the bug in action here: https://www.youtube.com/watch?v=UsJ8ZdLkBjE#t=10m30s
Tested with raw files from Canon 350D and 5D mark iii as well as a JPEG file. The bug behaves the same with all file types.
Bug verified in version: 1.3+714~g454b78a