Decide what parts of the Java embedder rendering APIs to deprecate #148557
Labels
c: proposal
A detailed proposal for a change to Flutter
c: tech-debt
Technical debt, code quality, testing, etc.
platform-android
Android applications specifically
team-android
Owned by Android platform team
In Flutter 3.22, we've formally instructed users to stop using the
{create|register}SurfaceTexture
family of APIs and instead to usecreateSurfaceProducer
, which, as an implementation detail, picks the right Surface-backed implementation. This is due to Impeller using Vulkan on newish Android APIs, and Vulkan not supporting OpenGL-basedSurfaceTexture
s.The next step in #139702 is deprecate APIs we don't expect users to need or use anymore (as of flutter/engine#52892 we issue error messages on the C++ engine side). For sake of scope, let's focus on
io.flutter.view.TextureRegistry
and known implementing classes.Here is my proposal of APIs to deprecate, but I'd like feedback:
P1: Will no longer work in Impeller
We should do this before Impeller becomes the default.
.SurfaceTextureEntry
SurfaceProducer
..createSurfaceTexture
SurfaceProducer
..registerSurfaceTexture
SurfaceProducer
.P2: Unused or no longer useful as part of the public API
These are nice-to-have cleanups, we should do the ones that make sense.
.GLTextureConsumer
.ImageConsumer
registerImageTexture
is no longer public..ImageTextureEntry
registerImageTexture
is no longer public..OnFrameConsumedListener
@VisibleForTesting
, 1 usage..OnTrimMemoryListener
.TextureEntry
SurfaceProducer
..createImageTexture
.onTrimMemory
Assigned @jonahwilliams and @johnmccutchan to review while I'm on vacation 😎
The text was updated successfully, but these errors were encountered: