-
Notifications
You must be signed in to change notification settings - Fork 6k
[impeller] enable framebuffer blit when available #56596
Conversation
In the current state, images that are resized are rendered upside down. |
We need to set the upload intent differently |
Try changing the coordinate system on the destination texture in the resize.
|
Ugh, that works. I don't like it. It seems wrong editing the destination when blitting to it. Looks like we are doing this elsewhere though. |
@@ -92,7 +92,7 @@ AndroidContextGLImpeller::AndroidContextGLImpeller( | |||
} | |||
|
|||
impeller::egl::ConfigDescriptor desc; | |||
desc.api = impeller::egl::API::kOpenGLES2; | |||
desc.api = impeller::egl::API::kOpenGLES3; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this valid to do? Defiintely outside of my wheelhouse. - we do a lot of GLES 2 stuff, do we need to worry about GLES 3 having different semantics?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nope. That's how you'd do it. ES3 is backwards compatible with the same sematics.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coolio
1ca589b
to
4b3781a
Compare
There appears to be tests for the software path in |
@@ -104,6 +104,15 @@ TEST_F(AndroidContextGLImpellerTest, FallbackForEmulator) { | |||
EXPECT_CALL( | |||
*display, | |||
ChooseConfig(Matcher<ConfigDescriptor>(AllOf( | |||
Field(&ConfigDescriptor::api, impeller::egl::API::kOpenGLES3), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jonahwilliams looks like we could have used these tests for asserting we are asking for a depth buffer. It had been a while since I looked at these.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought I did that by adding EGL_DEPTH_SIZE 24 above?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤷♂️
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@@ -109,6 +109,10 @@ CapabilitiesGLES::CapabilitiesGLES(const ProcTableGLES& gl) { | |||
default_glyph_atlas_format_ = PixelFormat::kR8UNormInt; | |||
} | |||
|
|||
if (desc->GetGlVersion().major_version >= 3) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Completely off topic, but we should do a GL version check in ProcTableGLES and reset or not bother to resolve FOR_EACH_IMPELLER_GLES3_PROC methods when we less than ES 3. On older versions of Android, I remember seeing instances where we'd get a function pointer for ES3 functions even on ES2 contexts but those wouldn't work if called.
When I first wrote that bit, I didn't think we'd ever resolve ES3 procs. So its a blind spot.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yea, absolutely agree. I can file an issue.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Drat, the added test is a playground test, but isn't wired up to be a golden test. I'd like to get that addressed so the test is automated. |
Golden file changes have been found for this pull request. Click here to view and triage (e.g. because this is an intentional change). If you are still iterating on this change and are not ready to resolve the images on the Flutter Gold dashboard, consider marking this PR as a draft pull request above. You will still be able to view image results on the dashboard, commenting will be silenced, and the check will not try to resolve itself until marked ready for review. |
test: exists in #56596 fixes: flutter/flutter#158995 [C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
…159093) flutter/engine@9686de1...766370b 2024-11-18 30870216+gaaclarke@users.noreply.github.com Started only loading gles3 functions if we have a gles3 context (flutter/engine#56636) 2024-11-18 30870216+gaaclarke@users.noreply.github.com [impeller] enable framebuffer blit when available (flutter/engine#56596) 2024-11-18 skia-flutter-autoroll@skia.org Roll Skia from 7594233ff914 to 0b74d5c3eb4f (4 revisions) (flutter/engine#56678) 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 jimgraham@google.com,zra@google.com 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://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
…159097) flutter/engine@9686de1...878f593 2024-11-18 chris@bracken.jp EmbedderTest: Extract backend-specific user_data (flutter/engine#56642) 2024-11-18 skia-flutter-autoroll@skia.org Roll Dart SDK from ae5111067032 to 625e0a9cb67a (1 revision) (flutter/engine#56679) 2024-11-18 30870216+gaaclarke@users.noreply.github.com Started only loading gles3 functions if we have a gles3 context (flutter/engine#56636) 2024-11-18 30870216+gaaclarke@users.noreply.github.com [impeller] enable framebuffer blit when available (flutter/engine#56596) 2024-11-18 skia-flutter-autoroll@skia.org Roll Skia from 7594233ff914 to 0b74d5c3eb4f (4 revisions) (flutter/engine#56678) 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 jimgraham@google.com,zra@google.com 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://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
…159097) flutter/engine@9686de1...878f593 2024-11-18 chris@bracken.jp EmbedderTest: Extract backend-specific user_data (flutter/engine#56642) 2024-11-18 skia-flutter-autoroll@skia.org Roll Dart SDK from ae5111067032 to 625e0a9cb67a (1 revision) (flutter/engine#56679) 2024-11-18 30870216+gaaclarke@users.noreply.github.com Started only loading gles3 functions if we have a gles3 context (flutter/engine#56636) 2024-11-18 30870216+gaaclarke@users.noreply.github.com [impeller] enable framebuffer blit when available (flutter/engine#56596) 2024-11-18 skia-flutter-autoroll@skia.org Roll Skia from 7594233ff914 to 0b74d5c3eb4f (4 revisions) (flutter/engine#56678) 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 jimgraham@google.com,zra@google.com 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://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
depends on flutter/engine#56573 fixes flutter#158523 ## Pre-launch Checklist - [x] I read the [Contributor Guide] and followed the process outlined there for submitting PRs. - [x] I read the [Tree Hygiene] wiki page, which explains my responsibilities. - [x] I read and followed the [Flutter Style Guide] and the [C++, Objective-C, Java style guides]. - [x] I listed at least one issue that this PR fixes in the description above. - [x] I added new tests to check the change I am making or feature I am adding, or the PR is [test-exempt]. See [testing the engine] for instructions on writing and running engine tests. - [x] I updated/added relevant documentation (doc comments with `///`). - [x] I signed the [CLA]. - [x] All existing and new tests are passing. If you need help, consider asking for advice on the #hackers-new channel on [Discord]. <!-- Links --> [Contributor Guide]: https://github.com/flutter/flutter/wiki/Tree-hygiene#overview [Tree Hygiene]: https://github.com/flutter/flutter/wiki/Tree-hygiene [test-exempt]: https://github.com/flutter/flutter/wiki/Tree-hygiene#tests [Flutter Style Guide]: https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo [C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style [testing the engine]: https://github.com/flutter/flutter/wiki/Testing-the-engine [CLA]: https://cla.developers.google.com/ [flutter/tests]: https://github.com/flutter/tests [breaking change policy]: https://github.com/flutter/flutter/wiki/Tree-hygiene#handling-breaking-changes [Discord]: https://github.com/flutter/flutter/wiki/Chat
…ter/engine#56636) test: exists in flutter/engine#56596 fixes: flutter#158995 [C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
depends on #56573
fixes flutter/flutter#158523
Pre-launch Checklist
///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.