This ensures FlutterMetalTexture.destruction_callback gets called.
FlutterRendererConfig.get_next_drawable_callback holds a callback used by the embedder API to request a drawable; in the case of Metal, this drawable is a FlutterMetalTexture.
FlutterMetalTexture.destruction_callback should be called when it's safe to release resources associated with the FlutterMetalTexture. This callback is not currently invoked for textures returned via FlutterRendererConfig.get_next_drawable_callback; instead we unpack the returned struct and pass it on.
In the compositor codepath, we do create an SkSurface that triggers the destruction callback, here:
bbdb5d6a3e/shell/platform/embedder/embedder.cc (L868-L881)
Issue: https://github.com/flutter/flutter/issues/116381
This adds explicit strong/copy Objective-C property annotations where
they were previously implied on NSObject properties and fixes on case
where it was previously improperly specified.
Previously there were two conventions for test filenames in the macOS
embedder: some ended in Unittests.mm and others eneded in Test.mm. This
applies a consistent naming convention, which is also consistent with
the iOS and common Darwin tests. Stock C++ unittests should continue to
use the _unittests.cc convention.
* [Impeller] use uniform array for more efficient small gradients
* ++
* Make this work on Android
* ++
* ++
* ++
* compiler support and basic feature detection
* ++
* ++
* rename to ssbo_fill, move to context
* ++
* ++
* ++
* tests
* ++
* ++
* only clip when necessary
tests
fix tests
format
review
fix
add scenario tset
more scenario tests
add docs and comments
use offset.zero
* remove mistakenly checked-in code
Now that OpenGL support has been removed from the macOS embedder, we
merge FlutterRenderBackingStore and its only implementing subclass,
FlutterMetalRenderBackingStore, and similarly
FlutterRenderBackingStoreProvider and its only implementing subclass
FlutterMetalRenderBackingStoreProvider.
Issue: https://github.com/flutter/flutter/issues/108304
Issue: https://github.com/flutter/flutter/issues/114445
Previously, FlutterSurfaceManager was a protocol with two concrete
implementations: FlutterGLSurfaceManager and FlutterMetalSurfaceManager.
Most of the implementation was in a shared superclass,
FlutterIOSurfaceManager, which called into the OpenGL or Metal-specific
subclass when backend-specific operations (such as allocating textures)
was required. It did so via a delegate pattern, wherein the subclasses
both implemented the FlutterIOSurfaceManagerDelegate protocol that
exposed the backend-specific functionality.
Now that only the Metal implementation remains, the delegate code can be
inlined into the calling functions, and the class hierarchy can be
squashed into a single concrete implementation class,
FlutterSurfaceManager, similar to how it was originally implemented in
https://github.com/flutter/engine/pull/21525 before we had two backends.
Issue: https://github.com/flutter/flutter/issues/108304
Issue: https://github.com/flutter/flutter/issues/114445
Previously, external textures were modelled in the macOS embedder by a
top-level FlutterMacOSExternalTexture protocol with a single textureID
getter, and two implementations: FlutterExternalTextureGL and
FlutterExternalTextureMetal.
With the removal of OpenGL support from the macOS embedder, the only
remaining external texture implementation is Metal. This patch squashes
this set of types into a single FlutterExternalTexture class.
Issue: https://github.com/flutter/flutter/issues/108304
Issue: https://github.com/flutter/flutter/issues/114445
In the Virtual Display codepath for Android platform views, resize
completes asynchronously. Currently it is attempting to access the
Context in the completion handler, but there is no guarantee that it
is still present at that point, leading to possible null pointer
crashes.
This adds a check for the current state of the Context, and uses a
fallback if it's not available.
Fixes https://github.com/flutter/flutter/issues/114095
Now that OpenGL support in Flutter on macOS has been removed, the only
FlutterCompositor implementation is the Metal-based compositor. This
patch merges it into the FlutterCompositor base class since there's no
longer any reason to keep the interface separate from its implementation.
This patch will be followed by similar patches for the renderer, surface
manager, and external textures.
Issue: https://github.com/flutter/flutter/issues/108304
Issue: https://github.com/flutter/flutter/issues/114445
This capability is being removed by the Fuchsia platform (https://fuchsia-review.git.corp.google.com/c/fuchsia/+/758606), but is currently blocked on this usage.
This change simply removes the capability from this tests, where it doesn't seem to be used at all.
Now that the macOS embedders have all been updated to use a minimum
macOS SDK of 10.14, eliminate the remaining @available checks dependent
on that version.
Issue: https://github.com/flutter/flutter/issues/114445
* Use fuchsia_component
* [mouse-input] mouse-input-view doc nits and add mouse-input-test to the run_integration_test.sh script
Co-authored-by: Erik <erkln@google.com>
* add methods
* add empty test
* add unit test
* Update licenses_flutter
* add const
* size -> get length
* add boundary checks
* add tests
* remove death test since it says "Death tests use fork(), which is unsafe particularly in a threaded context."