1 /* 2 * Copyright 2021 Google Inc. 3 * 4 * Use of this source code is governed by a BSD-style license that can be 5 * found in the LICENSE file. 6 */ 7 8 #ifndef skgpu_MtlTrampoline_DEFINED 9 #define skgpu_MtlTrampoline_DEFINED 10 11 #include "include/core/SkRefCnt.h" 12 13 namespace skgpu { 14 class Gpu; 15 } 16 17 namespace skgpu::mtl { 18 struct BackendContext; 19 20 /* 21 * This class is used to hold functions which trampoline from the Graphite cpp code 22 * to the Mtl Objective-C files. 23 */ 24 class Trampoline { 25 public: 26 static sk_sp<skgpu::Gpu> MakeGpu(const BackendContext&); 27 }; 28 29 } // namespace skgpu::mtl 30 31 #endif // skgpu_MtlTrampoline_DEFINED 32 33