168 {
169#if !defined(SK_DISABLE_SDF_TEXT)
171#else
173#endif
174
175 if (skGlyph.
image() ==
nullptr) {
177 }
179
181 MaskFormat expectedMaskFormat = this->resolveMaskFormat(glyphFormat);
183
184 int padding;
185 switch (srcPadding) {
186 case 0:
187
188 padding = 0;
189 if (fSupportBilerpAtlas) {
190
191 padding = 1;
192 srcPadding = 1;
193 }
194 break;
195 case 1:
196
197 padding = 1;
198 break;
199#if !defined(SK_DISABLE_SDF_TEXT)
201
202
203
204
205 padding = 0;
206 break;
207#endif
208 default:
209
211 }
212
213 const int width = skGlyph.
width() + 2*padding;
215 int rowBytes =
width * bytesPerPixel;
217
218
220 void* dataPtr = storage.get();
221 if (padding > 0) {
223
224 dataPtr = (char*)(dataPtr) + rowBytes + bytesPerPixel;
225 }
226
228
230 auto errorCode =
atlas->addToAtlas(fRecorder,
233 storage.get(),
235
238 }
239
240 return errorCode;
241}
#define SK_DistanceFieldInset
static void sk_bzero(void *buffer, size_t size)
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