Fix loading fully transparent TGA images in 32 bpp

This commit is contained in:
David Capello 2020-03-25 11:11:13 -03:00
parent 319c89c2ad
commit 538dc9e6aa
2 changed files with 6 additions and 1 deletions

View File

@ -181,6 +181,11 @@ bool TgaFormat::onLoad(FileOp* fop)
return false;
}
// Fix alpha values for RGB images
decoder.postProcessImage(header, tgaImage);
// Post process gray image pixels (because we use grayscale images
// with alpha).
if (header.isGray()) {
doc::LockImageBits<GrayscaleTraits> bits(image);
for (auto it=bits.begin(), end=bits.end(); it != end; ++it) {

@ -1 +1 @@
Subproject commit 90f54d1100840b4c82f4d289fc9a8ae209ccc59c
Subproject commit d821575f5284d56429909fc4c69579562d06a4f6