Commit Graph

509 Commits

Author SHA1 Message Date
Kaushik Iska e65b4901fa [animator] Pass target frametime for Window.onBeginFrame (#14318)
This gives us a time closer to when the frame will be rendered on
screen.

Fixes: https://github.com/flutter/flutter/issues/10850
2019-12-12 15:03:27 -08:00
Kaushik Iska e0e0ac0a68 [testing] Make vsync waiters pluggable in shell_unittests (#14463)
This makes it so that the platform views can be passed
an arbitraty CreateVsyncWaiter callback that lets us inject
a vsync waiter other than just the simulated monotonic vsync waiter
that currently exists.
2019-12-12 14:15:36 -08:00
Kaushik Iska ffbe2a40e7 [testing] Move test vsync waiters to their own TUs (#14456)
This move makes it easier to add more vsync waiters.
2019-12-12 12:27:56 -08:00
Kaushik Iska 9bafb3cd3c [tests] Use distinct begin and end times (#14361) 2019-12-11 17:23:49 -08:00
Jim Graham 85953615eb Conditionally use offscreen root surface only when needed
Currently helps primarily on iOS when no BackdropFilter is present by lowering energy usage
2019-12-11 15:10:55 -08:00
liyuqian 212fbbaf82 Cleanup the IO thread GrContext (#14265)
Fixes https://github.com/flutter/flutter/issues/19558

This is tested by the devicelab test fast_scroll_large_images__memory
2019-12-10 16:02:02 -08:00
David Worsham d117ac979c Wire up Opacity on Fuchsia, round 2 (#14024)
* Remove erroneous ChildView opacity

* Wire frame metrics through contexts

* Maintain layer stack inside of SceneBuilder

* Remove EnsureSingleChild

* Centralize system-composite and elevation logic

* Wire up OpacityLayer to Scenic
2019-12-04 19:29:31 -08:00
David Worsham 2fc1e1bce1 Relanding: Add Flow unittests and fixtures (#14091) 2019-12-03 14:33:02 -08:00
liyuqian 84bf72917c Revert PRs to unblock David and Jim's work (#14088)
* Revert "Add flow test fixtures and tests (#13986)"

This reverts commit 620f5281b8.

* Revert "Dynamically determine whether to use offscreen surface based on need (#13976)"

This reverts commit a86ef94656.
2019-12-03 12:02:37 -08:00
David Worsham 620f5281b8 Add flow test fixtures and tests (#13986) 2019-12-03 09:43:02 -08:00
Jim Graham a86ef94656 Dynamically determine whether to use offscreen surface based on need (#13976)
Only use an offscreen surface on iOS if a layer which reads back from the destination surface, such as BackdropFilter, is present.
2019-11-27 15:01:25 -08:00
Chinmay Garde ca68af252c Add a separate target for Dart coverter on FML types. (#14011)
The converters are still in a separate target that must be included manually. This allows targets that depend on FML but not Dart runtime not have to depend on the runtime.

Adds a test that includes this target and tests image decompression from assets. There is also a test for the standalone DartConvertor in shell_unittests but not in fml_unittests be cause FML uni-tests cannot yet launch a VM. I will work on adding fixtures for those.
2019-11-26 13:33:56 -08:00
Jason Simmons c7ec5bbc1c Convert images to raster on the GPU thread for Image.toByteData (#13647)
If the image is a cross-context image that might be read from the GPU thread
during onscreen rendering, then it is not safe to read it concurrently from
the IO thread as part of Image.toByteData.

If the GPU thread does not have a graphics context, then fall back to
converting the image on the IO thread.

Fixes https://github.com/flutter/flutter/issues/30697
2019-11-25 14:44:57 -08:00
gaaclarke 97a23a80e1 Made a way to turn off the OpenGL operations on the IO thread for backgrounded apps (#13908) 2019-11-22 14:08:33 -08:00
gaaclarke 89e395853c Refactor to passing functions by const ref (#13975)
Moved our code to passing functions by const ref
2019-11-22 12:20:02 -08:00
George Wright 537590377e Ensure we use the base CompositorContext's AcquireFrame method when screenshotting (#13934)
This ensures we rasterize into the canvas passed in as subclasses may reimplement AcquireFrame in different ways that don't utilize the canvas object passed in (such as Fuchsia's flutter_runner::CompositorContext).
2019-11-20 14:09:27 -08:00
chunhtai 132d38cd22 Moves pointer event sanitizing to engine. (#13697)
* Moves pointer event sanitizing to engine

* fix comment format

* fix formatting

* addressing comment

* fix format

* fix format

* addressing comment
2019-11-19 09:48:25 -08:00
Todd Volkert 762294cf2d Revert "RendererContextSwitch guard flutter's gl context rework. (#13812)" (#13906)
This reverts commit f456423cfb.

This is being reverted because it caused flutter/flutter#45098
(images don't load on iOS).
2019-11-18 18:28:04 -08:00
Jonah Williams cb8d7bc569 Allow passing hot reload debugging flags through dart-flags (#13780) 2019-11-14 19:12:27 -08:00
Chris Yang f456423cfb RendererContextSwitch guard flutter's gl context rework. (#13812) 2019-11-14 11:50:45 -08:00
Jim Graham bb7d76248c Avoid GL calls when compiling for Fuchsia. (#13847)
* Avoid GL calls when compiling for Fuchsia.
2019-11-13 16:41:03 -08:00
chunhtai 1f1e2ba58e reland add lifecycle enum (#13767)
This reverts commit 8ebb318401.
2019-11-13 11:26:25 -08:00
Chris Yang 6d66993b1d Revert "Reland "Guarding EAGLContext used by Flutter #13314" (#13759)" (#13788)
This reverts commit 2dcfaaeb5d.
2019-11-11 17:17:18 -08:00
Jason Simmons ce0e9e79e6 Fix RendererContextSwitch result check in Rasterizer::MakeRasterSnapshot (#13785)
Fixes https://github.com/flutter/flutter/issues/31355
2019-11-11 15:46:26 -08:00
Chris Yang 2dcfaaeb5d Reland "Guarding EAGLContext used by Flutter #13314" (#13759) 2019-11-08 20:09:18 -08:00