178 {
179#if !defined(SK_DISABLE_SDF_TEXT)
181#else
183#endif
184
185 if (skGlyph.
image() ==
nullptr) {
187 }
189
191 MaskFormat expectedMaskFormat = this->resolveMaskFormat(glyphFormat);
193
194 int padding;
195 switch (srcPadding) {
196 case 0:
197
198 padding = 0;
199 if (fSupportBilerpAtlas) {
200
201 padding = 1;
202 srcPadding = 1;
203 }
204 break;
205 case 1:
206
207 padding = 1;
208 break;
209#if !defined(SK_DISABLE_SDF_TEXT)
211
212
213
214
215 padding = 0;
216 break;
217#endif
218 default:
219
221 }
222
223 const int width = skGlyph.
width() + 2*padding;
225 int rowBytes =
width * bytesPerPixel;
227
228
230 void* dataPtr = storage.get();
231 if (padding > 0) {
233
234 dataPtr = (char*)(dataPtr) + rowBytes + bytesPerPixel;
235 }
236
238
240 auto errorCode =
atlas->addToAtlas(fRecorder,
243 storage.get(),
245
248 }
249
250 return errorCode;
251}
sk_bzero(glyphs, sizeof(glyphs))
#define SK_DistanceFieldInset
SkMask::Format maskFormat() const
const void * image() const
void insetSrc(int padding)
skgpu::AtlasLocator fAtlasLocator
static skgpu::MaskFormat FormatFromSkGlyph(SkMask::Format format)
sk_sp< const SkImage > atlas
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive keep the shell running after the Dart script has completed enable serial On low power devices with low core running concurrent GC tasks on threads can cause them to contend with the UI thread which could potentially lead to jank This option turns off all concurrent GC activities domain network JSON encoded network policy per domain This overrides the DisallowInsecureConnections switch Embedder can specify whether to allow or disallow insecure connections at a domain level old gen heap size
static void get_packed_glyph_image(const SkGlyph &glyph, int dstRB, MaskFormat expectedMaskFormat, void *dst)
constexpr int MaskFormatBytesPerPixel(MaskFormat format)
skgpu::graphite::DrawAtlas DrawAtlas