Bug report #16044
Raster: multiply causes NULLs to be painted in black
|Affected QGIS version:||master||Regression?:||No|
|Operating System:||Debian||Easy fix?:||No|
|Pull Request or Patch supplied:||No||Resolution:|
|Crashes QGIS or corrupts data:||No||Copied to github as #:||23959|
On current master, if I load a coloured TIFF, it is displayed correctly.
If I change the blending mode to Multiply, the NULLs (0s) are displayed black, and they remain black even if I switch back to Blending=Normal.
On 2.18, the same TIFF is displayed as expected.
See attached file.
#1 Updated by Giovanni Manghi about 6 years ago
- Priority changed from Normal to Severe/Regression
- Target version set to Version 3.0
Please choose the appropriate priority/target version/etc when filing tickets.
#2 Updated by Mathieu Pellerin - nIRV about 6 years ago
I can't reproduce on my system. Can you provide detailed steps to reproduce what your seeing?
#3 Updated by Paolo Cavallini about 6 years ago
- load sample raster --> shown correctly
- Layer properties > Style > Blending mode > Multiply --> black areas appear
- Layer properties > Style > Blending mode > Normal --> black areas remain
- loading the same raster again --> shown correctly
Thanks for checking.
#4 Updated by Paolo Cavallini about 6 years ago
Tested again, with freshly compiled master.
#5 Updated by Mathieu Pellerin - nIRV about 6 years ago
Paolo, your going through the layer properties, not the style dock. Is that correct?
I suspect the problem has to do with the renderer losing track of the alphaBand value. When you see the black areas, try opening the style dock, go to the transparency tab and check whether the transparency band combo box is set to none (on your tif that'd be wrong) or "band 4 (alpha)".
#6 Updated by Giovanni Manghi about 6 years ago
- Status changed from Open to Feedback
#7 Updated by Paolo Cavallini about 6 years ago
Layer properties, correct.
The transparency is set to Band4, switches to None when setting blending to multiplying. Setting it back to Band4 shows the raster as expected.
#8 Updated by Mathieu Pellerin - nIRV about 6 years ago
- Status changed from Feedback to Closed
Fixed in changeset 632f9c582579590f13a849d4a9791b9dbb35449e.
#9 Updated by Mathieu Pellerin - nIRV about 6 years ago
Paolo, np. It'd be useful if you can confirm the issue is gone on your machine.
#10 Updated by Paolo Cavallini about 6 years ago
Confirmed, thanks a lot.