Flutter Engine
The Flutter Engine
|
#include <ios_context_metal_skia.h>
Public Member Functions | |
IOSContextMetalSkia (MsaaSampleCount msaa_samples) | |
~IOSContextMetalSkia () | |
fml::scoped_nsobject< FlutterDarwinContextMetalSkia > | GetDarwinContext () const |
IOSRenderingBackend | GetBackend () const override |
Get the rendering backend used by this context. | |
sk_sp< GrDirectContext > | GetMainContext () const override |
Accessor for the Skia context associated with IOSSurfaces and the raster thread. | |
sk_sp< GrDirectContext > | GetResourceContext () const |
Public Member Functions inherited from flutter::IOSContext | |
virtual | ~IOSContext () |
Collects the context object. This must happen on the thread on which this object was created. | |
virtual std::shared_ptr< impeller::Context > | GetImpellerContext () const |
MsaaSampleCount | GetMsaaSampleCount () const |
Private Member Functions | |
sk_sp< GrDirectContext > | CreateResourceContext () override |
Create a resource context for use on the IO task runner. This resource context is used by Skia to upload texture to asynchronously and collect resources that are no longer needed on the render task runner. | |
std::unique_ptr< GLContextResult > | MakeCurrent () override |
When using client rendering APIs whose contexts need to be bound to a specific thread, the engine will call this method to give the on-screen context a chance to bind to the current thread. | |
std::unique_ptr< Texture > | CreateExternalTexture (int64_t texture_id, fml::scoped_nsobject< NSObject< FlutterTexture > > texture) override |
Creates an external texture proxy of the appropriate client rendering API. | |
Additional Inherited Members | |
Static Public Member Functions inherited from flutter::IOSContext | |
static std::unique_ptr< IOSContext > | Create (IOSRenderingAPI api, IOSRenderingBackend backend, MsaaSampleCount msaa_samples, const std::shared_ptr< const fml::SyncSwitch > &is_gpu_disabled_sync_switch) |
Create an iOS context object capable of creating the on-screen and off-screen GPU context for use by Skia. | |
Protected Member Functions inherited from flutter::IOSContext | |
IOSContext (MsaaSampleCount msaa_samples) | |
Definition at line 19 of file ios_context_metal_skia.h.
|
explicit |
Definition at line 17 of file ios_context_metal_skia.mm.
|
default |
|
overrideprivatevirtual |
Creates an external texture proxy of the appropriate client rendering API.
[in] | texture_id | The texture identifier |
[in] | texture | The texture |
Implements flutter::IOSContext.
Definition at line 52 of file ios_context_metal_skia.mm.
|
overrideprivatevirtual |
Create a resource context for use on the IO task runner. This resource context is used by Skia to upload texture to asynchronously and collect resources that are no longer needed on the render task runner.
nullptr
on failure. Implements flutter::IOSContext.
Definition at line 41 of file ios_context_metal_skia.mm.
|
overridevirtual |
Get the rendering backend used by this context.
Reimplemented from flutter::IOSContext.
Definition at line 28 of file ios_context_metal_skia.mm.
fml::scoped_nsobject< FlutterDarwinContextMetalSkia > flutter::IOSContextMetalSkia::GetDarwinContext | ( | ) | const |
Definition at line 24 of file ios_context_metal_skia.mm.
|
overridevirtual |
Accessor for the Skia context associated with IOSSurfaces and the raster thread.
There can be any number of resource contexts but this is the one context that will be used by surfaces to draw to the screen from the raster thread.
nullptr
on failure. Implements flutter::IOSContext.
Definition at line 32 of file ios_context_metal_skia.mm.
sk_sp< GrDirectContext > flutter::IOSContextMetalSkia::GetResourceContext | ( | ) | const |
Definition at line 36 of file ios_context_metal_skia.mm.
|
overrideprivatevirtual |
When using client rendering APIs whose contexts need to be bound to a specific thread, the engine will call this method to give the on-screen context a chance to bind to the current thread.
true
.false
.ResoruceMakeCurrent
method instead.Implements flutter::IOSContext.
Definition at line 46 of file ios_context_metal_skia.mm.