#import <FlutterSurfaceManager.h>
Instance Methods | |
(nullable instancetype) | - initWithDevice:commandQueue:layer:delegate: |
(nonnull FlutterSurface *) | - surfaceForSize: |
(void) | - presentSurfaces:atTime:notify: |
Properties | |
FlutterBackBufferCache * | backBufferCache |
NSArray< FlutterSurface * > * | frontSurfaces |
NSArray< CALayer * > * | layers |
FlutterSurfaceManager is responsible for providing and presenting Core Animation render surfaces and managing sublayers.
Owned by FlutterView
.
Definition at line 44 of file FlutterSurfaceManager.h.
- (nullable instancetype) initWithDevice: | (nonnull id< MTLDevice >) | device | |
commandQueue: | (nonnull id< MTLCommandQueue >) | commandQueue | |
layer: | (nonnull CALayer *) | containingLayer | |
delegate: | (nonnull id< FlutterSurfaceManagerDelegate >) | delegate | |
Initializes and returns a surface manager that renders to a child layer (referred to as the content layer) of the containing layer.
- (void) presentSurfaces: | (nonnull NSArray< FlutterSurfacePresentInfo * > *) | surfaces | |
atTime: | (CFTimeInterval) | presentationTime | |
notify: | (nullable dispatch_block_t) | notify | |
Sets the provided surfaces as contents of FlutterView. Will create, update and remove sublayers as needed.
Must be called on raster thread. This will schedule a commit on the platform thread and block the raster thread until the commit is done. The notify
block will be invoked on the platform thread and can be used to perform additional work, such as mutating platform views. It is guaranteed be called in the same CATransaction.
Referenced by flutter::testing::TEST().
- (FlutterSurface *) surfaceForSize: | (CGSize) | size |
Returns a back buffer surface of the given size to which Flutter can render content. A cached surface will be returned if available; otherwise a new one will be created.
Must be called on raster thread.
Definition at line 133 of file FlutterSurfaceManager.mm.
Referenced by flutter::testing::TEST().
|
readnonatomicassign |
Provided by category FlutterSurfaceManager(Private).
Definition at line 105 of file FlutterSurfaceManager.h.
Referenced by flutter::testing::TEST().
|
readnonatomicassign |
Provided by category FlutterSurfaceManager(Private).
Definition at line 106 of file FlutterSurfaceManager.h.
Referenced by flutter::testing::TEST().
|
readnonatomicassign |
Provided by category FlutterSurfaceManager(Private).
Definition at line 107 of file FlutterSurfaceManager.h.