Lines Matching refs:glyph
120 void SkTestTypeface::getAdvance(SkGlyph* glyph) { in getAdvance() argument
121 glyph->fAdvanceX = fTestFont->fWidths[glyph->getGlyphID()]; in getAdvance()
122 glyph->fAdvanceY = 0; in getAdvance()
129 void SkTestTypeface::getMetrics(SkGlyph* glyph) { in getMetrics() argument
130 glyph->fAdvanceX = fTestFont->fWidths[glyph->getGlyphID()]; in getMetrics()
131 glyph->fAdvanceY = 0; in getMetrics()
134 void SkTestTypeface::getPath(const SkGlyph& glyph, SkPath* path) { in getPath() argument
135 *path = *fTestFont->fPaths[glyph.getGlyphID()]; in getPath()
209 uint16_t glyph; in generateCharToGlyph() local
210 (void) fFace->onCharsToGlyphs((const void *) &uni, SkTypeface::kUTF16_Encoding, &glyph, 1); in generateCharToGlyph()
211 return glyph; in generateCharToGlyph()
214 void generateAdvance(SkGlyph* glyph) override { in generateAdvance() argument
215 fFace->getAdvance(glyph); in generateAdvance()
217 const SkVector advance = fMatrix.mapXY(SkFixedToScalar(glyph->fAdvanceX), in generateAdvance()
218 SkFixedToScalar(glyph->fAdvanceY)); in generateAdvance()
219 glyph->fAdvanceX = SkScalarToFixed(advance.fX); in generateAdvance()
220 glyph->fAdvanceY = SkScalarToFixed(advance.fY); in generateAdvance()
223 void generateMetrics(SkGlyph* glyph) override { in generateMetrics() argument
224 fFace->getMetrics(glyph); in generateMetrics()
226 const SkVector advance = fMatrix.mapXY(SkFixedToScalar(glyph->fAdvanceX), in generateMetrics()
227 SkFixedToScalar(glyph->fAdvanceY)); in generateMetrics()
228 glyph->fAdvanceX = SkScalarToFixed(advance.fX); in generateMetrics()
229 glyph->fAdvanceY = SkScalarToFixed(advance.fY); in generateMetrics()
232 fFace->getPath(*glyph, &path); in generateMetrics()
242 glyph->fLeft = ibounds.fLeft; in generateMetrics()
243 glyph->fTop = ibounds.fTop; in generateMetrics()
244 glyph->fWidth = ibounds.width(); in generateMetrics()
245 glyph->fHeight = ibounds.height(); in generateMetrics()
246 glyph->fMaskFormat = SkMask::kARGB32_Format; in generateMetrics()
249 void generateImage(const SkGlyph& glyph) override { in generateImage() argument
251 fFace->getPath(glyph, &path); in generateImage()
254 bm.installPixels(SkImageInfo::MakeN32Premul(glyph.fWidth, glyph.fHeight), in generateImage()
255 glyph.fImage, glyph.rowBytes()); in generateImage()
259 canvas.translate(-SkIntToScalar(glyph.fLeft), in generateImage()
260 -SkIntToScalar(glyph.fTop)); in generateImage()
267 void generatePath(const SkGlyph& glyph, SkPath* path) override { in generatePath() argument
268 fFace->getPath(glyph, path); in generatePath()