Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
third_party
skia
include
svg
SkSVGCanvas.h
Go to the documentation of this file.
1
/*
2
* Copyright 2015 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 SkSVGCanvas_DEFINED
9
#define SkSVGCanvas_DEFINED
10
11
#include "
include/core/SkTypes.h
"
12
13
#include <cstdint>
14
#include <memory>
15
16
class
SkCanvas
;
17
class
SkWStream
;
18
struct
SkRect
;
19
20
class
SK_API
SkSVGCanvas
{
21
public
:
22
enum
{
23
kConvertTextToPaths_Flag = 0x01,
// emit text as <path>s
24
kNoPrettyXML_Flag = 0x02,
// suppress newlines and tabs in output
25
kRelativePathEncoding_Flag = 0x04,
// use relative commands for path encoding
26
};
27
28
/**
29
* Returns a new canvas that will generate SVG commands from its draw calls, and send
30
* them to the provided stream. Ownership of the stream is not transfered, and it must
31
* remain valid for the lifetime of the returned canvas.
32
*
33
* The canvas may buffer some drawing calls, so the output is not guaranteed to be valid
34
* or complete until the canvas instance is deleted.
35
*
36
* The 'bounds' parameter defines an initial SVG viewport (viewBox attribute on the root
37
* SVG element).
38
*/
39
static
std::unique_ptr<SkCanvas>
Make
(
const
SkRect
& bounds,
SkWStream
*, uint32_t
flags
= 0);
40
};
41
42
#endif
SK_API
#define SK_API
Definition
SkAPI.h:35
Make
static std::unique_ptr< SkEncoder > Make(SkWStream *dst, const SkPixmap *src, const SkYUVAPixmaps *srcYUVA, const SkColorSpace *srcYUVAColorSpace, const SkJpegEncoder::Options &options)
Definition
SkJpegEncoderImpl.cpp:259
SkTypes.h
SkCanvas
Definition
SkCanvas.h:106
SkSVGCanvas
Definition
SkSVGCanvas.h:20
SkWStream
Definition
SkStream.h:218
flags
FlutterSemanticsFlag flags
Definition
fl_accessible_node.cc:105
SkRect
Definition
extension.cpp:13
Generated on Fri Apr 26 2024 06:16:14 for Flutter Engine by
1.9.8