Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[Impeller] Use StrokePathSourceGeometry to stroke RoundSuperellipse#169704

Merged
auto-submit[bot] merged 10 commits into
flutter:masterfrom
dkwingsmt:rse-path-source
Jun 3, 2025
Merged

[Impeller] Use StrokePathSourceGeometry to stroke RoundSuperellipse#169704
auto-submit[bot] merged 10 commits into
flutter:masterfrom
dkwingsmt:rse-path-source

Conversation

@dkwingsmt
Copy link
Copy Markdown
Contributor

@dkwingsmt dkwingsmt commented May 29, 2025

This PR creates a new class, StrokeRoundSuperellipseGeometry, which reuses the StrokePathSourceGeometry class to stroke rounded superellipses.

Fixes #168419.

Filling is unchanged. I could have used FillPathSourceGeometry for non-uniform filling just like RRect, but I've decided not to after some experimentation, mostly because the RoundSuperellipseGeometry class wouldn't be simplified from uniformity as much as we hope for. This might be worthwhile if one day we move the filling code to Tessellator (just like FilledRoundRect), which reuses much existing code. But that's out of the scope for now.

Pre-launch Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

@flutter-dashboard
Copy link
Copy Markdown

It looks like this pull request may not have tests. Please make sure to add tests or get an explicit test exemption before merging.

If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix?

Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing.If you believe this PR qualifies for a test exemption, contact "@test-exemption-reviewer" in the #hackers channel in Discord (don't just cc them here, they won't see it!). The test exemption team is a small volunteer group, so all reviewers should feel empowered to ask for tests, without delegating that responsibility entirely to the test exemption group.

@dkwingsmt dkwingsmt requested a review from flar May 29, 2025 21:49
@github-actions github-actions Bot added engine flutter/engine related. See also e: labels. e: impeller Impeller rendering backend issues and features requests labels May 29, 2025
Copy link
Copy Markdown
Contributor

@flar flar left a comment

Choose a reason for hiding this comment

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

Do we have existing tests that would notice this change here? I don't expect goldens to change because it is identical to making a path, but we avoid the overhead of the storage. But, we should make sure we have a golden/playground test that exercises it before we ask for a test exemption.

Comment thread engine/src/flutter/impeller/geometry/round_superellipse.cc Outdated
@dkwingsmt
Copy link
Copy Markdown
Contributor Author

dkwingsmt commented May 29, 2025

RoundedSuperellipseBorder has been applied to many Cupertino widgets, such as the buttons, which can be used to verify the behavior. The following screenshot shows a CupertinoButton, which shows border when focused. Do you think this counts? (Such widgets are also backed by golden tests, which shouldn't change.)
image

@flar
Copy link
Copy Markdown
Contributor

flar commented May 29, 2025

RoundedSuperellipseBorder has been applied to many Cupertino widgets, such as the buttons, which can be used to verify the behavior. The following screenshot shows a CupertinoButton, which shows border when focused. Do you think this counts? (Such widgets are also backed by golden tests, which shouldn't change.)

That looks stroked. Use that as justification and ask for a test exemption.

@flutter-dashboard
Copy link
Copy Markdown

CI had a failure that stopped further tests from running. We need to investigate to determine the root cause.

SHA at time of execution: d8275c4.

Possible causes:

  • Configuration Changes: The .ci.yaml file might have been modified between the creation of this pull request and the start of this test run. This can lead to ci yaml validation errors.
  • Infrastructure Issues: Problems with the CI environment itself (e.g., quota) could have caused the failure.

A blank commit, or merging to head, will be required to resume running CI for this PR.

Error Details:

GitHub Error: You have exceeded a secondary rate limit. Please wait a few minutes before you try again. If you reach out to GitHub Support for help, please include the request ID 9FC6:1D72A4:6C8D73:DBA2F6:6838F02F.

Stack trace:

#0      GitHub.handleStatusCode (package:github/src/common/github.dart:486:5)
#1      GitHub.request (package:github/src/common/github.dart:422:7)
<asynchronous suspension>
#2      GitHub.requestJson (package:github/src/common/github.dart:323:22)
<asynchronous suspension>
#3      RetryOptions.retry (package:retry/retry.dart:131:16)
<asynchronous suspension>
#4      LuciBuildService.scheduleTryBuilds (package:cocoon_service/src/service/luci_build_service.dart:245:24)
<asynchronous suspension>
#5      Scheduler._runCiTestingStage (package:cocoon_service/src/service/scheduler.dart:1233:9)
<asynchronous suspension>
#6      Scheduler.proceedToCiTestingStage (package:cocoon_service/src/service/scheduler.dart:1294:7)
<asynchronous suspension>
#7      Scheduler._closeSuccessfulEngineBuildStage (package:cocoon_service/src/service/scheduler.dart:1105:5)
<asynchronous suspension>
#8      Scheduler.processCheckRunCompletion (package:cocoon_service/src/service/scheduler.dart:1038:9)
<asynchronous suspension>
#9      Scheduler.processCheckRun (package:cocoon_service/src/service/scheduler.dart:1378:9)
<asynchronous suspension>
#10     GithubWebhookSubscription.post (package:cocoon_service/src/request_handlers/github/webhook_subscription.dart:115:24)
<asynchronous suspension>
#11     RequestHandler.service (package:cocoon_service/src/request_handling/request_handler.dart:45:20)
<asynchronous suspension>
#12     SubscriptionHandler.service (package:cocoon_service/src/request_handling/subscription_handler.dart:140:5)
<asynchronous suspension>
#13     createServer.<anonymous closure> (package:cocoon_service/server.dart:317:7)
<asynchronous suspension>

Copy link
Copy Markdown
Contributor

@flar flar left a comment

Choose a reason for hiding this comment

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

LGTM

@stuartmorgan-g
Copy link
Copy Markdown
Contributor

test-exempt: code refactor with no semantic change

@dkwingsmt dkwingsmt added the autosubmit Merge PR when tree becomes green via auto submit App label Jun 3, 2025
@auto-submit auto-submit Bot added this pull request to the merge queue Jun 3, 2025
Merged via the queue into flutter:master with commit a686424 Jun 3, 2025
182 checks passed
@flutter-dashboard flutter-dashboard Bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Jun 3, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 4, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 4, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 4, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 4, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 4, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 5, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 5, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 5, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 5, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 5, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 5, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 5, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jun 5, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Aug 14, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Aug 14, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Aug 15, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Aug 15, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Aug 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

e: impeller Impeller rendering backend issues and features requests engine flutter/engine related. See also e: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Impeller] Render Superellipses as a PathSource instead of converting to a Path

3 participants