Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide layer bounds for text-shadow rendering #50415

Merged
merged 1 commit into from
Jan 31, 2025

Conversation

chromium-wpt-export-bot
Copy link
Collaborator

Lower layers have trouble culling away the shadows (and/or overestimate
their bounds) which lead to high raster costs.

Pass the computed visual rect for the text fragment when setting up the
layer for the shadow. This appears to reduce the raster cost
significantly in the case described in the bug.

Add a physical version of InkOverflow::ExpandForShadowOverflow and
simplify the application of the text-shadow ink overflow contribution.
This also fixes an issue where the ink overflow was miscalculated for
the vertical-lr writing mode.

Guard with the flag "TextShadowPaintingOptimization".

Bug: 391914237
Change-Id: I847d0a8291150ec1a92d4e7424c3a09eeecca134
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6213771
Commit-Queue: Fredrik Söderquist <[email protected]>
Reviewed-by: Stephen Chenney <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1414139}

Lower layers have trouble culling away the shadows (and/or overestimate
their bounds) which lead to high raster costs.

Pass the computed visual rect for the text fragment when setting up the
layer for the shadow. This appears to reduce the raster cost
significantly in the case described in the bug.

Add a physical version of InkOverflow::ExpandForShadowOverflow and
simplify the application of the text-shadow ink overflow contribution.
This also fixes an issue where the ink overflow was miscalculated for
the vertical-lr writing mode.

Guard with the flag "TextShadowPaintingOptimization".

Bug: 391914237
Change-Id: I847d0a8291150ec1a92d4e7424c3a09eeecca134
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6213771
Commit-Queue: Fredrik Söderquist <[email protected]>
Reviewed-by: Stephen Chenney <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1414139}
Copy link
Collaborator

@wpt-pr-bot wpt-pr-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The review process for this patch is being conducted in the Chromium project.

@chromium-wpt-export-bot chromium-wpt-export-bot merged commit 2dcaea3 into master Jan 31, 2025
20 checks passed
@chromium-wpt-export-bot chromium-wpt-export-bot deleted the chromium-export-cb2e5b9c1f branch January 31, 2025 16:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants