Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

[Impeller] Disable blending for Source blend mode #43162

Merged
merged 1 commit into from
Jun 24, 2023

Conversation

bdero
Copy link
Member

@bdero bdero commented Jun 23, 2023

All of the backends already respect this property for the first color attachment in the pipeline. Our Vulkan backend disables blending for a whole pipeline if the first color attachment has blending turned off. This has been under our nose but I haven't checked it until now.

HSR might not be working on some Vulkan & OpenGLES drivers because of this.

@bdero bdero self-assigned this Jun 23, 2023
@flutter-dashboard
Copy link

It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption to this rule, contact Hixie on the #hackers channel in Chat (don't just cc him here, he won't see it! He's on Discord!).

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.

@bdero
Copy link
Member Author

bdero commented Jun 23, 2023

@jonahwilliams
Copy link
Member

I'm not sure if I understand the description here.

Our Vulkan backend disables blending for a whole pipeline if the first color attachment has blending turned off

Is this what you are adding? or a non-deseriable behavior. Sorry, unlcear.

I do remember the discussion about disabling blending and IIRC it made no different for metal, but not surprised if it does for Vulkan.

@bdero
Copy link
Member Author

bdero commented Jun 24, 2023

Is this what you are adding? or a non-deseriable behavior. Sorry, unlcear.

Sorry, disregard -- I explained it wrong in the desc and the behavior of the Vulkan backend is correct. Blend configs (including enabling/disabling) is per-attachment. This patch just flips the (already working) flag off when it makes sense. :)

@bdero
Copy link
Member Author

bdero commented Jun 24, 2023

I do remember the discussion about disabling blending and IIRC it made no different for metal, but not surprised if it does for Vulkan.

Yeah, Apple seems to be smart about it. HSR Just Works when the blend ops match Source blending.

Copy link
Member

@jonahwilliams jonahwilliams left a comment

Choose a reason for hiding this comment

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

LGTM

@bdero bdero merged commit 84e80c5 into flutter:main Jun 24, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jun 24, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jun 24, 2023
fluttermirroringbot pushed a commit to flutter/flutter that referenced this pull request Jun 24, 2023
…129493)

flutter/engine@72c902c...5b1b983

2023-06-24 [email protected] Roll Fuchsia Mac SDK from JF0sJRpJH8KiyyqrR... to N0MQ5J5y_hQoiOYs9... (flutter/engine#43180)
2023-06-24 [email protected] [Impeller] Disable blending for Source blend mode (flutter/engine#43162)

Also rolling transitive DEPS:
  fuchsia/sdk/core/mac-amd64 from JF0sJRpJH8Ki to N0MQ5J5y_hQo

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-engine-flutter-autoroll
Please CC [email protected],[email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
No open projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants