Lines Matching refs:skPaint
378 const SkPaint& skPaint,
384 grPaint->setAntiAlias(skPaint.isAntiAlias());
386 // Setup the initial color considering the shader, the SkPaint color, and the presence or not
393 } else if (const SkShader* shader = skPaint.getShader()) {
395 skPaint.getFilterQuality()));
416 GrColor shaderInput = SkColorToOpaqueGrColor(skPaint.getColor());
434 GrColor paintAlpha = SkColorAlphaToGrColor(skPaint.getColor());
441 grPaint->setColor(SkColorToUnpremulGrColor(skPaint.getColor()));
449 GrConstColorProcessor::Create(SkColorToOpaqueGrColor(skPaint.getColor()),
463 grPaint->setColor(SkColorToOpaqueGrColor(skPaint.getColor()));
465 GrColor paintAlpha = SkColorAlphaToGrColor(skPaint.getColor());
472 grPaint->setColor(SkColorToPremulGrColor(skPaint.getColor()));
477 SkColorFilter* colorFilter = skPaint.getColorFilter();
480 grPaint->setColor(SkColorToPremulGrColor(colorFilter->filterColor(skPaint.getColor())));
492 // When the xfermode is null on the SkPaint (meaning kSrcOver) we need the XPFactory field on
495 SkXfermode* xfermode = skPaint.getXfermode();
503 if (skPaint.isDither() && grPaint->numColorFragmentProcessors() > 0) {
510 bool SkPaintToGrPaint(GrContext* context, const SkPaint& skPaint, const SkMatrix& viewM,
512 return skpaint_to_grpaint_impl(context, skPaint, viewM, nullptr, nullptr, false, grPaint);
515 /** Replaces the SkShader (if any) on skPaint with the passed in GrFragmentProcessor. */
517 const SkPaint& skPaint,
523 return skpaint_to_grpaint_impl(context, skPaint, SkMatrix::I(), &shaderFP, nullptr, false,
527 /** Ignores the SkShader (if any) on skPaint. */
529 const SkPaint& skPaint,
534 return skpaint_to_grpaint_impl(context, skPaint, SkMatrix::I(), kIgnoreShader, nullptr, false,
538 /** Blends the SkPaint's shader (or color if no shader) with a per-primitive color which must
541 const SkPaint& skPaint,
546 return skpaint_to_grpaint_impl(context, skPaint, viewM, nullptr, &primColorMode, primitiveIsSrc,
551 const SkPaint& paint,