Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
REGRESSION(251359@main) Subtitles in PiP and Fullscreen are blank
https://bugs.webkit.org/show_bug.cgi?id=242239 Reviewed by Simon Fraser. ImageBuffer::sinkToImage() would call ImageBuffer::drawConsuming() with the srcRect = FloatRect { 0, 0, -1, -1 } with the intention that it would mean to use the full source size. This intention was derived from the drawConsuming srcRect default argument. In reality, this would be a no-op. Fix by using the explicit source size. Also remove the ImageBuffer::drawConsuming() and ImageBuffer::draw() default arguments, as those would render the calls no-ops. Add tests for ImageBuffer::sinkToImage() for all testable configurations. * Source/WebCore/platform/graphics/ImageBuffer.cpp: (WebCore::ImageBuffer::sinkIntoImage): * Source/WebCore/platform/graphics/ImageBuffer.h: (WebCore::ImageBuffer::draw): (WebCore::ImageBuffer::drawConsuming): * Tools/TestWebKitAPI/TestUtilities.h: (WebCore::operator<<): * Tools/TestWebKitAPI/Tests/WebCore/ImageBufferTests.cpp: (TestWebKitAPI::imageBufferPixelIs): (TestWebKitAPI::hasTestPattern): (TestWebKitAPI::drawTestPattern): (TestWebKitAPI::TEST): (TestWebKitAPI::PrintTo): (TestWebKitAPI::PreserveResolutionOperationTest::deviceScaleFactor const): (TestWebKitAPI::PreserveResolutionOperationTest::imageBufferOptions const): (TestWebKitAPI::PreserveResolutionOperationTest::operationPreserveResolution): (TestWebKitAPI::TEST_P): Canonical link: https://commits.webkit.org/252193@main
- Loading branch information
1 parent
8b32054
commit bf1f57b
Showing
4 changed files
with
152 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters