2 * Copyright 2015 Xamarin Inc.
3 * Copyright 2017 Microsoft Corporation. All rights reserved.
5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file.
9 #include "SkManagedPixelSerializer.h"
11 static use_delegate fUse = nullptr;
12 static encode_delegate fEncode = nullptr;
14 SkManagedPixelSerializer::SkManagedPixelSerializer() {
17 void SkManagedPixelSerializer::setDelegates(const use_delegate pUse, const encode_delegate pEncode)
23 bool SkManagedPixelSerializer::onUseEncodedData(const void* data, size_t len) {
24 return ::fUse(this, data, len);
27 SkData* SkManagedPixelSerializer::onEncode(const SkPixmap& pixmap) {
28 return ::fEncode(this, pixmap);