Skip to content

Commit

Permalink
read unspecified extra samples (#261)
Browse files Browse the repository at this point in the history
  • Loading branch information
Cristy committed Aug 26, 2023
1 parent 42398d9 commit c46a3a0
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions coders/tiff.c
Original file line number Diff line number Diff line change
Expand Up @@ -1622,18 +1622,19 @@ static Image *ReadTIFFImage(const ImageInfo *image_info,
else
for (i=0; i < extra_samples; i++)
{
image->matte=MagickTrue;
if (sample_info[i] == EXTRASAMPLE_ASSOCALPHA)
{
image->matte=MagickTrue;
SetQuantumAlphaType(quantum_info,AssociatedQuantumAlpha);
(void) SetImageProperty(image,"tiff:alpha","associated");
break;
}
else
if (sample_info[i] == EXTRASAMPLE_UNASSALPHA)
{
image->matte=MagickTrue;
SetQuantumAlphaType(quantum_info,DisassociatedQuantumAlpha);
(void) SetImageProperty(image,"tiff:alpha","unassociated");
break;
}
}
if (image->matte != MagickFalse)
Expand Down

0 comments on commit c46a3a0

Please sign in to comment.