Closed tst-lsavoie closed 4 years ago
@duvifn do you have time to review and test this PR? If you are happy with the code and it passes your tests, you can click on the "Files Changed" tab above, then on "Review Changes" at the top right and approve the PR.
FYI, I'm going to be unavailable for the next few days but will come back to this mid next week.
@tst-lsavoie Thanks! This looks good to me and also tested with the given use case.
I also checked this with multi layer project (bluemarble + clipped raster) to ensure that regular blending still works.
I've run a number of tests on this and everything works as expected. No problems found.
Fixes #1785
Thanks to @duvifn for discovering the problem and suggesting a solution.
The problem:
Fusion caches alpha bands to make building multiple layers more efficient. However, it checks for the existence of the alpha band before using it because 4.x did not cache alpha. This is a problem because sometimes the check for the cached alpha happens before it has been built, so Fusion incorrectly decides that there is no alpha and does not apply transparency correctly.
The fix:
This PR moves the check for the cached alpha folder to just before it is used so that it has time to build it if it needs to.
To verify: