| Flutter iOS Embedder |

ios_external_texture_metal.mm
Go to the documentation of this file.
1 // Copyright 2013 The Flutter Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #import "flutter/shell/platform/darwin/ios/ios_external_texture_metal.h"
6 #include "flow/layers/layer.h"
7
8 namespace flutter {
9
10 IOSExternalTextureMetal::IOSExternalTextureMetal(
11 const fml::scoped_nsobject<FlutterDarwinExternalTextureMetal>& darwin_external_texture_metal)
12 : Texture([darwin_external_texture_metal textureID]),
13 darwin_external_texture_metal_(darwin_external_texture_metal) {}
14
15 IOSExternalTextureMetal::~IOSExternalTextureMetal() = default;
16
17 void IOSExternalTextureMetal::Paint(PaintContext& context,
18 const SkRect& bounds,
19 bool freeze,
20 const DlImageSampling sampling) {
21 [darwin_external_texture_metal_ paintContext:context
22 bounds:bounds
23 freeze:freeze
24 sampling:sampling];
25 }
26
27 void IOSExternalTextureMetal::OnGrContextCreated() {
28 [darwin_external_texture_metal_ onGrContextCreated];
29 }
30
31 void IOSExternalTextureMetal::OnGrContextDestroyed() {
32 [darwin_external_texture_metal_ onGrContextDestroyed];
33 }
34
35 void IOSExternalTextureMetal::MarkNewFrameAvailable() {
36 [darwin_external_texture_metal_ markNewFrameAvailable];
37 }
38
39 void IOSExternalTextureMetal::OnTextureUnregistered() {
40 [darwin_external_texture_metal_ onTextureUnregistered];
41 }
42
43 } // namespace flutter
flutter::IOSExternalTextureMetal::~IOSExternalTextureMetal
~IOSExternalTextureMetal()
flutter
Definition: accessibility_bridge.h:28
ios_external_texture_metal.h
flutter::IOSExternalTextureMetal::IOSExternalTextureMetal
IOSExternalTextureMetal(const fml::scoped_nsobject< FlutterDarwinExternalTextureMetal > &darwin_external_texture_metal)
Definition: ios_external_texture_metal.mm:10