1 /* 2 * Copyright 2021 Google LLC 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_graphite_MtlGraphiteUtilsPriv_DEFINED 9 #define skgpu_graphite_MtlGraphiteUtilsPriv_DEFINED 10 11 #include "include/ports/SkCFObject.h" 12 #include "src/gpu/graphite/ResourceTypes.h" 13 14 #include <string_view> 15 16 #import <Metal/Metal.h> 17 18 namespace skgpu { 19 class ShaderErrorHandler; 20 } 21 22 namespace skgpu::graphite { 23 24 class MtlSharedContext; 25 26 sk_cfp<id<MTLLibrary>> MtlCompileShaderLibrary(const MtlSharedContext* sharedContext, 27 std::string_view label, 28 std::string_view msl, 29 ShaderErrorHandler* errorHandler); 30 } // namespace skgpu::graphite 31 32 #endif // skgpu_graphite_MtlGraphiteUtilsPriv_DEFINED 33