-
-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handle raster layer's transparency band while rendering (fix #2491) #52
Conversation
Excellent stuff! Will test it shortly. Regards Tim |
Furthermore, IMHO all those draw private methods (i.e. 7 methods) should be merged in 2 or max 3 methods, the first one for one-band rasters (singleband and paletted) and the second for multi-band rasters because in this moment almost all their code is duplicated. Next step will be make GDAL provider able to get the mask band and set it as the raster layer's transparency band (see #4159). |
Hi Yes that list of separate methods was written by me a loooong time ago and hasnt really undergone any revision since. If you have a better way go for it. It would be nice to fix the misreporting of pixel depth and inability to render certain images that was introduced with raster reprojection - or at least not let it regress any further. Regards Tim |
Hi I tested it and it seems to work fine for me. I would like to do further testing and having a unit test added to the test suite would be nice, but I will merge this in the mean time and we can consider a backport of it to the release branch. Regards Tim |
[BACKPORT] Handle raster layer's transparency band while rendering (fix #2491)
This patch allow to set a transparency band for raster layers from Layer -> Property ->Transparency. The combobox to select the transparency band was present yet, but it was disabled because not implemented yet.
Of course I tried it and it works well, but further tests are welcome for this kind of rendering related stuff.
I also think this commit should be backported, that grayed combobox is very annoying for users.