Package io.flutter.view
Interface TextureRegistry
- All Known Implementing Classes:
FlutterRenderer
,FlutterView
public interface TextureRegistry
Registry of backend textures used with a single
FlutterView
instance. Entries may be
embedded into the Flutter view using the Texture widget.-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic interface
static interface
static interface
static interface
Listener invoked when the most recent image has been consumed.static interface
Listener invoked when a memory pressure warning was forward.static interface
Uses a Surface to populate the texture.static interface
A registry entry for a managed SurfaceTexture.static interface
An entry in the texture registry. -
Method Summary
Modifier and TypeMethodDescriptionCreates and registers a texture managed by the Flutter engine.Creates and registers a SurfaceProducer texture managed by the Flutter engine.Creates and registers a SurfaceTexture managed by the Flutter engine.default void
onTrimMemory
(int level) Callback invoked when memory is low.registerSurfaceTexture
(SurfaceTexture surfaceTexture) Registers a SurfaceTexture managed by the Flutter engine.
-
Method Details
-
createSurfaceProducer
Creates and registers a SurfaceProducer texture managed by the Flutter engine.- Returns:
- A SurfaceProducer.
-
createSurfaceTexture
Creates and registers a SurfaceTexture managed by the Flutter engine.- Returns:
- A SurfaceTextureEntry.
-
registerSurfaceTexture
@NonNull TextureRegistry.SurfaceTextureEntry registerSurfaceTexture(@NonNull SurfaceTexture surfaceTexture) Registers a SurfaceTexture managed by the Flutter engine.- Returns:
- A SurfaceTextureEntry.
-
createImageTexture
Creates and registers a texture managed by the Flutter engine.- Returns:
- a ImageTextureEntry.
-
onTrimMemory
default void onTrimMemory(int level) Callback invoked when memory is low.Invoke this from
Activity.onTrimMemory(int)
.
-