103 {
109 char op = '\0';
110 char previousOp = '\0';
111 bool relative = false;
112 for (;;) {
113 if (!data) {
114
115 return false;
116 }
118 if (data[0] == '\0') {
119 break;
120 }
122 if (
is_digit(ch) || ch ==
'-' || ch ==
'+' || ch ==
'.') {
123 if (op == '\0' || op == 'Z') {
124 return false;
125 }
128 } else {
129 op = ch;
130 relative = false;
133 relative = true;
134 }
137 }
138 switch (op) {
139 case 'M':
142 previousOp = '\0';
143 op = 'L';
145 break;
146 case 'L':
150 break;
151 case 'H': {
156 } break;
157 case 'V': {
162 } break;
163 case 'C':
165 goto cubicCommon;
166 case 'S':
169 if (previousOp == 'C' || previousOp == 'S') {
172 }
173 cubicCommon:
177 break;
178 case 'Q':
180 goto quadraticCommon;
181 case 'T':
184 if (previousOp == 'Q' || previousOp == 'T') {
187 }
188 quadraticCommon:
192 break;
193 case 'A': {
196 bool largeArc, sweep;
197 if ((data =
find_points(data, &radii, 1,
false,
nullptr))
209 }
210 } break;
211 case 'Z':
213 c = first;
214 break;
215 case '~': {
220 } break;
221 default:
222 return false;
223 }
224 if (previousOp == 0) {
225 first = c;
226 }
227 previousOp = op;
228 }
229
231 return true;
232}
static const int points[]
static int to_upper(int c)
static const char * find_flag(const char str[], bool *value)
static const char * find_scalar(const char str[], SkScalar *value, bool isRelative, SkScalar relative)
static const char * find_points(const char str[], SkPoint value[], int count, bool isRelative, SkPoint *relative)
static bool is_lower(int c)
static bool is_sep(int c)
static const char * skip_sep(const char str[])
static bool is_digit(int c)
static const char * skip_ws(const char str[])
G_BEGIN_DECLS G_MODULE_EXPORT FlValue * args
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir path
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot data