Home | History | Annotate | Download | only in text

Lines Matching refs:skPaint

27 bool GrAtlasTextContext::canDraw(const SkPaint& skPaint,
31 return GrTextUtils::CanDrawAsDistanceFields(skPaint, viewMatrix, props, shaderCaps) ||
32 !SkDraw::ShouldDrawTextAsPaths(skPaint, viewMatrix);
35 GrColor GrAtlasTextContext::ComputeCanonicalColor(const SkPaint& paint, bool lcd) {
70 const GrClip& clip, const SkPaint& skPaint,
85 const SkMaskFilter* mf = skPaint.getMaskFilter();
86 bool canCache = !(skPaint.getPathEffect() ||
102 ComputeCanonicalColor(skPaint, hasLCD);
106 key.fStyle = skPaint.getStyle();
115 if (!SkPaintToGrPaint(context, skPaint, viewMatrix, &grPaint)) {
120 if (cacheBlob->mustRegenerate(skPaint, grPaint.getColor(), blurRec, viewMatrix, x, y)) {
125 cacheBlob.reset(SkRef(cache->createCachedBlob(blob, key, blurRec, skPaint)));
127 *context->caps()->shaderCaps(), skPaint, grPaint.getColor(),
138 sanityBlob->setupKey(key, blurRec, skPaint);
140 *context->caps()->shaderCaps(), skPaint,
148 cacheBlob.reset(SkRef(cache->createCachedBlob(blob, key, blurRec, skPaint)));
153 *context->caps()->shaderCaps(), skPaint, grPaint.getColor(),
158 cacheBlob->flushCached(context, dc, blob, props, fDistanceAdjustTable, skPaint,
165 const SkPaint& skPaint, GrColor color,
173 SkPaint runPaint = skPaint;
185 runPaint = skPaint;
246 runPaint = skPaint;
256 const SkPaint& skPaint,
261 int glyphCount = skPaint.countText(text, byteLength);
266 if (GrTextUtils::CanDrawAsDistanceFields(skPaint, viewMatrix, props, shaderCaps)) {
268 skPaint, paint.getColor(), viewMatrix, text,
271 GrTextUtils::DrawBmpText(blob, 0, fontCache, props, skPaint,
280 const SkPaint& skPaint,
285 int glyphCount = skPaint.countText(text, byteLength);
290 if (GrTextUtils::CanDrawAsDistanceFields(skPaint, viewMatrix, props, shaderCaps)) {
292 skPaint, paint.getColor(), viewMatrix, text,
295 GrTextUtils::DrawBmpPosText(blob, 0, fontCache, props, skPaint,
305 const GrPaint& paint, const SkPaint& skPaint,
312 } else if (this->canDraw(skPaint, viewMatrix, props, *context->caps()->shaderCaps())) {
316 paint, skPaint,
319 blob->flushThrowaway(context, dc, props, fDistanceAdjustTable, skPaint, paint,
325 GrTextUtils::DrawTextAsPath(context, dc, clip, skPaint, viewMatrix, text, byteLength, x, y,
332 const GrPaint& paint, const SkPaint& skPaint,
340 } else if (this->canDraw(skPaint
345 paint, skPaint, viewMatrix, props,
349 blob->flushThrowaway(context, dc, props, fDistanceAdjustTable, skPaint, paint,
355 GrTextUtils::DrawPosTextAsPath(context, dc, props, clip, skPaint, viewMatrix, text,
375 // Setup dummy SkPaint / GrPaint
378 SkPaint skPaint;
379 skPaint.setColor(color);
380 skPaint.setLCDRenderText(random->nextBool());
381 skPaint.setAntiAlias(skPaint.isLCDRenderText() ? true : random->nextBool());
382 skPaint.setSubpixelText(random->nextBool());
385 if (!SkPaintToGrPaint(context, skPaint, viewMatrix, &grPaint)) {
406 *context->caps()->shaderCaps(), grPaint, skPaint,
411 return blob->test_createBatch(textLen, 0, 0, viewMatrix, x, y, color, skPaint,