[Webkit-unassigned] [Bug 90445] Add a comment in order to clarify why BitmapImage::frameHasAlphaAtIndex returns true as default.
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Jul 3 16:57:37 PDT 2012
https://bugs.webkit.org/show_bug.cgi?id=90445
--- Comment #7 from Eric Seidel <eric at webkit.org> 2012-07-03 16:57:37 PST ---
(From update of attachment 150579)
View in context: https://bugs.webkit.org/attachment.cgi?id=150579&action=review
>>> Source/WebCore/platform/graphics/BitmapImage.cpp:322
>>> + // When a frame has not finished decoding, always mark it as having alpha.
>>
>> The comment was copied from ImageSource::frameHasAlphaAtIndex(size_t index)
>
> The comment of ImageSource::frameHasAlphaAtIndex is long, so I pasted just summary of the comment to BitmapImage::frameHasAlphaAtIndex.
>
> bool ImageSource::frameHasAlphaAtIndex(ImageFrame* buffer)
> {
> // When a frame has not finished decoding, always mark it as having alpha.
> // Ports that check the result of this function to determine their
> // compositing op need this in order to not draw the undecoded portion as
> // black.
> // TODO: Perhaps we should ensure that each individual decoder returns true
> // in this case.
> return !frameIsCompleteAtIndex(buffer) || buffer->hasAlpha();
> }
You should add a line that said:
// See ImageSource::framehasAlphaAtIndex for explanation of why incomplete images claim to have alpha.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list