Flutter Engine
 
Loading...
Searching...
No Matches
FlutterSurface Class Reference

#include <FlutterSurface.h>

Inheritance diagram for FlutterSurface:

Instance Methods

(FlutterMetalTexture- asFlutterMetalTexture
 
(nonnull instancetype) - initWithSize:device:
 

Class Methods

(nullable FlutterSurface *) + fromFlutterMetalTexture:
 

Properties

IOSurfaceRef ioSurface
 
CGSize size
 
int64_t textureId
 
BOOL isInUse
 
BOOL isInUseOverride
 

Detailed Description

Opaque surface type. Can be represented as FlutterMetalTexture to cross the embedder API boundary.

Definition at line 16 of file FlutterSurface.h.

Method Documentation

◆ asFlutterMetalTexture

- (FlutterMetalTexture) asFlutterMetalTexture

Definition at line 17 of file FlutterSurface.mm.

56 {
59 .texture_id = self.textureId,
60 .texture = (__bridge void*)_texture,
61 // Retain for use in [FlutterSurface fromFlutterMetalTexture]. Released in
62 // destruction_callback.
63 .user_data = (__bridge_retained void*)self,
64 .destruction_callback =
65 [](void* user_data) {
66 // Balancing release for the retain when setting user_data above.
67 FlutterSurface* surface = (__bridge_transfer FlutterSurface*)user_data;
68 surface = nil;
69 },
70 };
71}
id< FlutterTexture > _texture
VkSurfaceKHR surface
Definition main.cc:65
FlTexture * texture
size_t struct_size
The size of this struct. Must be sizeof(FlutterMetalTexture).
Definition embedder.h:855
int64_t texture_id

◆ fromFlutterMetalTexture:

+ (nullable FlutterSurface *) fromFlutterMetalTexture: (nonnull const FlutterMetalTexture *)  texture

Referenced by flutter::testing::TEST().

◆ initWithSize:device:

- (nonnull instancetype) initWithSize: (CGSize)  size
device: (nonnull id< MTLDevice >)  device 

Provided by category FlutterSurface(Private).

Property Documentation

◆ ioSurface

- (IOSurfaceRef) ioSurface
readnonatomicassign

Provided by category FlutterSurface(Private).

Definition at line 32 of file FlutterSurface.h.

◆ isInUse

- (BOOL) isInUse
readnonatomicassign

Provided by category FlutterSurface(Private).

Definition at line 36 of file FlutterSurface.h.

◆ isInUseOverride

- (BOOL) isInUseOverride
readwritenonatomicassign

Provided by category FlutterSurface(Testing).

Definition at line 41 of file FlutterSurface.h.

◆ size

- (CGSize) size
readnonatomicassign

Provided by category FlutterSurface(Private).

Definition at line 33 of file FlutterSurface.h.

◆ textureId

- (int64_t) textureId
readnonatomicassign

Provided by category FlutterSurface(Private).

Definition at line 34 of file FlutterSurface.h.


The documentation for this class was generated from the following files: