381 Commits

Author SHA1 Message Date
Jonah Williams
0ecfed28d3 [Impeller] read from framebuffer for advanced blends on iOS. (flutter/engine#39567)
* [impeller] read from framebuffer for advanced blends

* ++

* update to contents

* move to separate contents

* ++

* set stencil depth duh

* ++

* ++

* remove debug info

* update licenses

* Add FML_OS_PHYSICAL_IOS

* ++

* ++
2023-02-14 21:27:07 +00:00
Brandon DeRosier
4d586c0346 Add Animated PNG demuxer (flutter/engine#31098) 2023-02-09 22:34:05 -08:00
Chris Bracken
1dd1f02bc4 Extract WideToUTF16String/UTF16StringToWide to FML (flutter/engine#39020) 2023-01-19 22:55:47 -08:00
godofredoc
aa2afcdeb5 Revert "Extract WideToUTF16String/UTF16StringToWide to FML (#39006)" (flutter/engine#39019)
This reverts commit d96d942ddc22af628e00ab958ec9860e338ce17f.
2023-01-20 00:45:58 +00:00
Chris Bracken
d96d942ddc Extract WideToUTF16String/UTF16StringToWide to FML (flutter/engine#39006)
* Extract WideToUTF16String/UTF16StringToWide to FML

In third_party/accessibility, for string conversion, we use a mix of:
* FML
* third_party/accessibility base string utility functions
* static functions local to the translation unit itself

This moves all conversions between UTF16 and wide strings to FML. Note
that this implementation is only safe on platforms where:
  * the size of wchar_t and char16_t are the same
  * the encoding of wchar_t and char16_t are both UTF-16
which is the case for Windows, hence why these functions are implemented
in a Windows-specific translation unit (wstring_conversion).

Issue: https://github.com/flutter/flutter/issues/118811

* Migrate UTF16ToWide as well
2023-01-19 23:46:59 +00:00
Jason Simmons
6c1389babe Clarify file sharing flags in FML filesystem APIs on Windows (flutter/engine#38164)
Use shared mode when requesting read access and exclusive mode for write access
2022-12-13 15:22:35 +00:00
fzyzcjy
52668a7252 Reland fix wrong VSYNC event (flutter/engine#37865) 2022-12-07 13:46:06 -05:00
gaaclarke
af036b8857 Turned on performance-unnecessary-value-param everywhere. (flutter/engine#37447)
* Turned on performance-unnecessary-value-param everywhere.

* linux host additions

* ios patch

* reverted bad fix

* revert bad fix

* another ios patch

* removed lint fix printer
2022-11-09 20:55:13 +00:00
Brandon DeRosier
9491b2c39b [Impeller] Remove cached pipelines when RuntimeStage is hot reloaded (flutter/engine#37307) 2022-11-04 17:18:02 -07:00
Jason Simmons
462cb1c9ad Convert the executable directory path to UTF-8 on Windows (flutter/engine#36908) 2022-10-21 00:28:20 +00:00
moko256
1ddb84552e Add Windows support for //flutter/fml/backtrace.h (flutter/engine#36202) 2022-10-20 20:10:25 +00:00
Jason Simmons
71c230958d Change TaskRunnerAffineWeakPtr to no longer be a subclass of WeakPtr (flutter/engine#36818) 2022-10-18 18:53:16 +00:00
Kaushik Iska
53383fbdf7 [Impeller] Add WSI support for Vulkan on Linux and Windows (flutter/engine#36762)
There are additional instance extensions that need to be enabled for
this. Having any one of them is sufficient on each of these platforms.
There were also some `VALIDATION_LOG`s that would fail in the process of
picking a valid physical device, this would incorrectly exit early when
there were multiple devices and a latter device is valid.

Also improves logging for playground when glfw fails to get a surface.
2022-10-17 11:11:40 -05:00
Dan Field
e4d709de85 Avoid using non-UTF-8 encoded argv more often (flutter/engine#36590) 2022-10-05 12:03:20 -07:00
gaaclarke
e41c775200 Removed instances of unnecessary values (flutter/engine#36221) 2022-09-26 21:28:04 +00:00
Jason Simmons
136cbcc67f [Impeller] Convert the ImpellerC command line arguments to UTF-8 on Windows (flutter/engine#36335) 2022-09-22 15:13:09 +00:00
Alexander Biggs
6751734343 [fuchsia] Add run_unit_tests.sh script. (flutter/engine#36308)
This is a convenience script for running unit tests locally.

To make this script work, I had to move several test exclusions
from test_suites.yaml (which controls running tests on CQ)
to the tests themselves. I think this is for the best because
it makes running the tests locally with behavior that matches
CQ easier.

Also added fuchsia_tests to build_and_copy_to_fuchsia.sh
so it builds the unit tests .far packages by default.

Tested: Ran `run_unit_tests.sh`, all tests pass. Ran
`build_and_copy_to_fuchsia.sh`, it still builds.
2022-09-21 10:40:20 -07:00
Brandon DeRosier
9ce1286f2b Resolve warnings on Windows (flutter/engine#36241) 2022-09-19 05:49:54 -07:00
Brandon DeRosier
b029ab4f73 [Impeller] Header fixes to make fml/impeller buildable against libstdc++ (flutter/engine#36240) 2022-09-19 05:49:26 -07:00
Chris Bracken
b693201c04 [lint] Update local variable names in fml (#36136) (flutter/engine#36147)
This updates local variable names to use clang `lower_case` style in the
fml directory. This is one of several patches to update our variable
names to a consistent style before enabling enforcement in our
clang-tidy rules.

This is a formatting-only change with no intended semantic change.
2022-09-14 15:47:25 -07:00
Dan Field
08312a825e Lint and fix bugprone-use-after-move violations (flutter/engine#35978) 2022-09-09 02:41:03 +00:00
gaaclarke
7a54d02e79 allows mallocmapping copies of size zero (flutter/engine#35803) 2022-08-30 18:10:25 +00:00
Tamir Duberstein
2aaeab3c9d Remove fx_logger_config_t.console_fd (flutter/engine#35302)
This was deprecated in https://fxrev.dev/708606.
2022-08-11 15:02:22 -07:00
Jason Simmons
23d5f04e7b Retain a reference to the CFRunLoop until MessageLoopDarwin::Terminate exits (flutter/engine#34735) 2022-07-19 16:56:06 +00:00
klaxxi
bec0d79eeb remove lock and use raw ptr for MessageLoopTaskQueues (flutter/engine#34249) 2022-07-18 07:08:04 +00:00
Jason Simmons
722630e73a Disable libcxx deprecation warnings for FML's use of UTF-16 string converters (flutter/engine#34551) 2022-07-08 22:37:04 +00:00
Chris Bracken
53a9648da9 [lint] Merge impeller .clang-tidy into main config (flutter/engine#33692)
Merges most (but not all) of the impeller .clang-tidy rules into the
main .clang-tidy config. Merges:

readability-identifier-naming.PrivateMemberSuffix (_)
readability-identifier-naming.EnumConstantPrefix (k)
modernize-use-default-member-init.UseAssignment
Does not merge:

readability-identifier-naming.PublicMethodCase (CamelCase)
readability-identifier-naming.PrivateMethodCase (CamelCase)
These last two are not merged due to the non-trivial number of existing
field accessors that use field_name() methods to directly return
field_name_. While these are permitted by the C++ style guide, we may
want to move to a single, simple rule and name everything in CamelCase.
These can be enabled in a followup patch.

No new tests added, since this change is style-only.
2022-06-21 11:52:42 -07:00
ColdPaleLight
412e090f98 Remove duplicate 'FML_DCHECK' in 'MessageLoopImpl::PostTask' (flutter/engine#34061) 2022-06-16 00:33:06 -07:00
Jonah Williams
b30f87212c Use std::filesystem to compute output paths in blobcat and impellerc (flutter/engine#33939) 2022-06-09 15:48:05 -07:00
Zachary Anderson
8e85a8d270 Fixes a few asan errors (flutter/engine#33632) 2022-05-26 07:29:50 -07:00
David Worsham
88c5519cfa [fuchsia] Migrate unittests to CFv2 (flutter/engine#32878) 2022-05-06 18:54:05 -07:00
Chris Bracken
09285aac02 Use empty in place of size checks vs 0 (flutter/engine#33151) 2022-05-06 13:09:04 -07:00
Zachary Anderson
98bfa2d298 Add an option to use a prebuilt impellerc (flutter/engine#33139) 2022-05-05 18:38:37 -07:00
Tamir Duberstein
d46454914d Remove reference to FX_LOG_ALL (flutter/engine#33027)
It was partially removed in
https://fuchsia-review.googlesource.com/c/fuchsia/+/674049; this commit
allows remaining references to be removed.
2022-05-01 07:06:35 -07:00
Zachary Anderson
ac2c30006a [fml] Pass OPEN_ALWAYS for create_if_necessary (flutter/engine#33033) 2022-04-30 21:06:17 -07:00
Zachary Anderson
511245230b [fml] Handle absolute paths on Windows (flutter/engine#33029) 2022-04-30 10:39:07 -07:00
Chris Bracken
0a84242538 WinUWP: Remove WinUWP sources, targets (flutter/engine#33019)
This removes:
* The Windows UWP emebedder sources and targets
* UWP-specific build targets
* UWP-specific code behind WINUWP #ifdefs
* UWP-specific TODOs.
* uwptool.exe sources and targets used for installing, uninstalling, and
  launching UWP apps.

This is a straight removal patch, and does not land any refactorings
made possible by removal of UWP support. Those patches will land in
followup refactorings.

Tool support was removed in:
https://github.com/flutter/flutter/pull/102174

The CI target was removed in:
https://github.com/flutter/engine/pull/33012

The Recipe was removed in:
https://flutter-review.googlesource.com/c/recipes/+/29500

GN build support was removed in:
https://github.com/flutter/engine/pull/33016

Issue: https://github.com/flutter/flutter/issues/102172
2022-04-29 18:39:36 -07:00
Jonah Williams
2b39f38143 fix impellerc on windows (flutter/engine#33003) 2022-04-29 14:39:02 -07:00
Dan Field
5c27c4acbf Avoid calling Dart_TimelineGetMicros when systrace is enabled (flutter/engine#32968) 2022-04-27 14:59:03 -07:00
Tamir Duberstein
f12e90982b Remove reference to deprecated field (flutter/engine#32964)
log_service_channel is being renamed to log_sink_socket.
2022-04-27 13:12:09 -07:00
Jason Simmons
d9de6d31cf Disable the timeline in release mode on Android unless systrace is enabled (flutter/engine#32909) 2022-04-26 10:54:03 -07:00
Dan Field
f51504259a Do not depend on Dart in FML (flutter/engine#32846) 2022-04-21 19:22:45 -07:00
Dan Field
9e46531319 Remove redundant trace events (flutter/engine#32812) 2022-04-21 13:28:03 -07:00
ColdPaleLight
eb3479dd86 Replace 'std::mutex' inside 'SyncSwitch' to 'fml::SharedMutex' (flutter/engine#32773) 2022-04-19 09:44:04 -07:00
Jason Simmons
c6a09145d7 Wrap the global timeline event handler callback in a std::atomic (flutter/engine#32073) 2022-03-16 16:10:06 -07:00
Ren You
c0958acf73 Add missing #include <algorithm> (flutter/engine#32003)
See b/222535478 and cl/433590918
2022-03-14 09:09:29 -07:00
Zachary Anderson
53e8808dcb Add include to header for coming libc++ updates (flutter/engine#31835) 2022-03-04 11:41:03 -08:00
Jonah Williams
75f0c30722 [win32] support high frame rates (flutter/engine#28927) 2022-03-03 12:06:06 -08:00
JsouLiang
f88b49b778 Add ThreadConfigSetter for Embedder api that can set thread priority (flutter/engine#31626) 2022-03-01 16:23:24 -08:00
Jason Simmons
da146d247c Revert "Reland "Listen for Vsync callback on the UI thread directly"" (flutter/engine#31750) 2022-03-01 15:06:11 -08:00