Flutter Engine
The Flutter Engine
SkOpenTypeSVGDecoder.h
Go to the documentation of this file.
1/*
2 * Copyright 2022 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 SkOpenTypeSVGDecoder_DEFINED
9#define SkOpenTypeSVGDecoder_DEFINED
10
12#include "include/core/SkSpan.h"
14
15#include <memory>
16
17class SkCanvas;
18
20public:
21 /** Each instance probably owns an SVG DOM.
22 * The instance may be cached so needs to report how much memory it retains.
23 */
24 virtual size_t approximateSize() = 0;
25 virtual bool render(SkCanvas&, int upem, SkGlyphID glyphId,
26 SkColor foregroundColor, SkSpan<SkColor> palette) = 0;
27 virtual ~SkOpenTypeSVGDecoder() = default;
28};
29
30#endif // SkOpenTypeSVGDecoder_DEFINED
uint32_t SkColor
Definition: SkColor.h:37
uint16_t SkGlyphID
Definition: SkTypes.h:179
virtual ~SkOpenTypeSVGDecoder()=default
virtual bool render(SkCanvas &, int upem, SkGlyphID glyphId, SkColor foregroundColor, SkSpan< SkColor > palette)=0
virtual size_t approximateSize()=0