1 /* 2 * Copyright 2022 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 ClientMappedBufferManager_graphite_DEFINED 9 #define ClientMappedBufferManager_graphite_DEFINED 10 11 #include "include/gpu/graphite/Context.h" 12 #include "src/gpu/AsyncReadTypes.h" 13 #include "src/gpu/graphite/Buffer.h" 14 15 namespace skgpu::graphite { 16 17 // This is declared as a class rather than an alias to allow for forward declarations 18 class ClientMappedBufferManager : 19 public skgpu::TClientMappedBufferManager<Buffer, Context::ContextID> { 20 public: ClientMappedBufferManager(Context::ContextID ownerID)21 ClientMappedBufferManager(Context::ContextID ownerID) 22 : TClientMappedBufferManager(ownerID) {} 23 }; 24 25 bool SkShouldPostMessageToBus(const ClientMappedBufferManager::BufferFinishedMessage&, 26 Context::ContextID potentialRecipient); 27 28 } // namespace skgpu::graphite 29 30 #endif 31