24 const std::shared_ptr<impeller::AiksContext>& context,
25 bool render_to_surface =
true);
31 bool IsValid()
override;
38 std::shared_ptr<impeller::AiksContext> aiks_context_;
39 id<MTLTexture> last_texture_;
44 bool render_to_surface_ =
true;
45 bool disable_partial_repaint_ =
false;
48 std::shared_ptr<std::map<void*, DlIRect>> damage_ =
49 std::make_shared<std::map<void*, DlIRect>>();
50 std::shared_ptr<impeller::SwapchainTransientsMTL> swapchain_transients_;
53 std::unique_ptr<SurfaceFrame> AcquireFrame(
54 const DlISize& frame_size)
override;
56 std::unique_ptr<SurfaceFrame> AcquireFrameFromCAMetalLayer(
59 std::unique_ptr<SurfaceFrame> AcquireFrameFromMTLTexture(
63 DlMatrix GetRootTransformation()
const override;
66 GrDirectContext* GetContext()
override;
69 std::unique_ptr<GLContextResult> MakeRenderContextCurrent()
override;
72 bool AllowsDrawingWhenGpuDisabled()
const override;
75 bool EnableRasterCache()
const override;
78 std::shared_ptr<impeller::AiksContext> GetAiksContext()
const override;