aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--include/gpu/GrDrawContext.h24
-rw-r--r--src/core/SkImageFilter.cpp2
-rw-r--r--src/effects/SkBlurMaskFilter.cpp4
-rw-r--r--src/effects/SkGpuBlurUtils.cpp8
-rw-r--r--src/effects/SkLightingImageFilter.cpp2
-rw-r--r--src/effects/SkMorphologyImageFilter.cpp6
-rw-r--r--src/gpu/GrBlurUtils.cpp2
-rw-r--r--src/gpu/GrDrawContext.cpp20
-rw-r--r--src/gpu/GrTextureParamsAdjuster.cpp2
-rw-r--r--src/gpu/SkGpuDevice.cpp26
-rw-r--r--src/gpu/effects/GrConfigConversionEffect.cpp30
11 files changed, 63 insertions, 63 deletions
diff --git a/include/gpu/GrDrawContext.h b/include/gpu/GrDrawContext.h
index b6fc0dfa23..d55818b6d7 100644
--- a/include/gpu/GrDrawContext.h
+++ b/include/gpu/GrDrawContext.h
@@ -111,27 +111,27 @@ public:
const GrStrokeInfo* strokeInfo = NULL);
/**
- * Maps a rectangle of shader coordinates to a rectangle and draws that rectangle
+ * Maps a rectangle of shader coordinates to a rectangle and fills that rectangle.
*
* @param paint describes how to color pixels.
* @param viewMatrix transformation matrix which applies to rectToDraw
* @param rectToDraw the rectangle to draw
* @param localRect the rectangle of shader coordinates applied to rectToDraw
*/
- void drawNonAARectToRect(const GrClip&,
- const GrPaint& paint,
- const SkMatrix& viewMatrix,
- const SkRect& rectToDraw,
- const SkRect& localRect);
+ void fillRectToRect(const GrClip&,
+ const GrPaint& paint,
+ const SkMatrix& viewMatrix,
+ const SkRect& rectToDraw,
+ const SkRect& localRect);
/**
- * Draws a non-AA rect with paint and a localMatrix
+ * Fills a rect with a paint and a localMatrix.
*/
- void drawNonAARectWithLocalMatrix(const GrClip& clip,
- const GrPaint& paint,
- const SkMatrix& viewMatrix,
- const SkRect& rect,
- const SkMatrix& localMatrix);
+ void fillRectWithLocalMatrix(const GrClip& clip,
+ const GrPaint& paint,
+ const SkMatrix& viewMatrix,
+ const SkRect& rect,
+ const SkMatrix& localMatrix);
/**
* Draw a roundrect using a paint.
diff --git a/src/core/SkImageFilter.cpp b/src/core/SkImageFilter.cpp
index 25eecb0b5d..abac24cf3f 100644
--- a/src/core/SkImageFilter.cpp
+++ b/src/core/SkImageFilter.cpp
@@ -380,7 +380,7 @@ bool SkImageFilter::filterImageGPU(Proxy* proxy, const SkBitmap& src, const Cont
SkAutoTUnref<GrDrawContext> drawContext(context->drawContext(dst->asRenderTarget()));
if (drawContext) {
- drawContext->drawNonAARectToRect(clip, paint, SkMatrix::I(), dstRect, srcRect);
+ drawContext->fillRectToRect(clip, paint, SkMatrix::I(), dstRect, srcRect);
WrapTexture(dst, bounds.width(), bounds.height(), result);
return true;
diff --git a/src/effects/SkBlurMaskFilter.cpp b/src/effects/SkBlurMaskFilter.cpp
index 5a25e54b41..5b5a4a033f 100644
--- a/src/effects/SkBlurMaskFilter.cpp
+++ b/src/effects/SkBlurMaskFilter.cpp
@@ -893,7 +893,7 @@ bool SkBlurMaskFilterImpl::directFilterMaskGPU(GrTextureProvider* texProvider,
return false;
}
- drawContext->drawNonAARectWithLocalMatrix(clip, *grp, SkMatrix::I(), rect, inverse);
+ drawContext->fillRectWithLocalMatrix(clip, *grp, SkMatrix::I(), rect, inverse);
return true;
}
@@ -1174,7 +1174,7 @@ bool SkBlurMaskFilterImpl::directFilterRRectMaskGPU(GrTextureProvider* texProvid
return false;
}
- drawContext->drawNonAARectWithLocalMatrix(clip, *grp, SkMatrix::I(), proxyRect, inverse);
+ drawContext->fillRectWithLocalMatrix(clip, *grp, SkMatrix::I(), proxyRect, inverse);
return true;
}
diff --git a/src/effects/SkGpuBlurUtils.cpp b/src/effects/SkGpuBlurUtils.cpp
index 5d6d014dfd..91ab9e00e0 100644
--- a/src/effects/SkGpuBlurUtils.cpp
+++ b/src/effects/SkGpuBlurUtils.cpp
@@ -60,7 +60,7 @@ static void convolve_gaussian_1d(GrDrawContext* drawContext,
texture, direction, radius, sigma, useBounds, bounds));
paint.addColorFragmentProcessor(conv);
SkMatrix localMatrix = SkMatrix::MakeTrans(srcOffset.x(), srcOffset.y());
- drawContext->drawNonAARectWithLocalMatrix(clip, paint, SkMatrix::I(), dstRect, localMatrix);
+ drawContext->fillRectWithLocalMatrix(clip, paint, SkMatrix::I(), dstRect, localMatrix);
}
static void convolve_gaussian_2d(GrDrawContext* drawContext,
@@ -83,7 +83,7 @@ static void convolve_gaussian_2d(GrDrawContext* drawContext,
useBounds ? GrTextureDomain::kClamp_Mode : GrTextureDomain::kIgnore_Mode,
true, sigmaX, sigmaY));
paint.addColorFragmentProcessor(conv);
- drawContext->drawNonAARectWithLocalMatrix(clip, paint, SkMatrix::I(), dstRect, localMatrix);
+ drawContext->fillRectWithLocalMatrix(clip, paint, SkMatrix::I(), dstRect, localMatrix);
}
static void convolve_gaussian(GrDrawContext* drawContext,
@@ -222,7 +222,7 @@ GrTexture* GaussianBlur(GrContext* context,
if (!dstDrawContext) {
return nullptr;
}
- dstDrawContext->drawNonAARectToRect(clip, paint, SkMatrix::I(), dstRect, srcRect);
+ dstDrawContext->fillRectToRect(clip, paint, SkMatrix::I(), dstRect, srcRect);
srcDrawContext.swap(dstDrawContext);
srcRect = dstRect;
@@ -345,7 +345,7 @@ GrTexture* GaussianBlur(GrContext* context,
if (!dstDrawContext) {
return nullptr;
}
- dstDrawContext->drawNonAARectToRect(clip, paint, SkMatrix::I(), dstRect, srcRect);
+ dstDrawContext->fillRectToRect(clip, paint, SkMatrix::I(), dstRect, srcRect);
srcDrawContext.swap(dstDrawContext);
srcRect = dstRect;
diff --git a/src/effects/SkLightingImageFilter.cpp b/src/effects/SkLightingImageFilter.cpp
index ecb4111158..3d3a069a29 100644
--- a/src/effects/SkLightingImageFilter.cpp
+++ b/src/effects/SkLightingImageFilter.cpp
@@ -353,7 +353,7 @@ void SkLightingImageFilterInternal::drawRect(GrDrawContext* drawContext,
GrPaint paint;
GrFragmentProcessor* fp = this->getFragmentProcessor(src, matrix, bounds, boundaryMode);
paint.addColorFragmentProcessor(fp)->unref();
- drawContext->drawNonAARectToRect(clip, paint, SkMatrix::I(), dstRect, srcRect);
+ drawContext->fillRectToRect(clip, paint, SkMatrix::I(), dstRect, srcRect);
}
bool SkLightingImageFilterInternal::filterImageGPU(Proxy* proxy,
diff --git a/src/effects/SkMorphologyImageFilter.cpp b/src/effects/SkMorphologyImageFilter.cpp
index 5b9141fd2a..94210872c3 100644
--- a/src/effects/SkMorphologyImageFilter.cpp
+++ b/src/effects/SkMorphologyImageFilter.cpp
@@ -477,7 +477,7 @@ void apply_morphology_rect(GrDrawContext* drawContext,
radius,
morphType,
bounds))->unref();
- drawContext->drawNonAARectToRect(clip, paint, SkMatrix::I(), SkRect::Make(dstRect),
+ drawContext->fillRectToRect(clip, paint, SkMatrix::I(), SkRect::Make(dstRect),
SkRect::Make(srcRect));
}
@@ -494,8 +494,8 @@ void apply_morphology_rect_no_bounds(GrDrawContext* drawContext,
direction,
radius,
morphType))->unref();
- drawContext->drawNonAARectToRect(clip, paint, SkMatrix::I(), SkRect::Make(dstRect),
- SkRect::Make(srcRect));
+ drawContext->fillRectToRect(clip, paint, SkMatrix::I(), SkRect::Make(dstRect),
+ SkRect::Make(srcRect));
}
void apply_morphology_pass(GrDrawContext* drawContext,
diff --git a/src/gpu/GrBlurUtils.cpp b/src/gpu/GrBlurUtils.cpp
index 5d691fb137..3d4c00d841 100644
--- a/src/gpu/GrBlurUtils.cpp
+++ b/src/gpu/GrBlurUtils.cpp
@@ -42,7 +42,7 @@ static bool draw_mask(GrDrawContext* drawContext,
if (!viewMatrix.invert(&inverse)) {
return false;
}
- drawContext->drawNonAARectWithLocalMatrix(clip, *grp, SkMatrix::I(), maskRect, inverse);
+ drawContext->fillRectWithLocalMatrix(clip, *grp, SkMatrix::I(), maskRect, inverse);
return true;
}
diff --git a/src/gpu/GrDrawContext.cpp b/src/gpu/GrDrawContext.cpp
index 82e1057c6a..ec26672b37 100644
--- a/src/gpu/GrDrawContext.cpp
+++ b/src/gpu/GrDrawContext.cpp
@@ -322,11 +322,11 @@ void GrDrawContext::drawRect(const GrClip& clip,
}
}
-void GrDrawContext::drawNonAARectToRect(const GrClip& clip,
- const GrPaint& paint,
- const SkMatrix& viewMatrix,
- const SkRect& rectToDraw,
- const SkRect& localRect) {
+void GrDrawContext::fillRectToRect(const GrClip& clip,
+ const GrPaint& paint,
+ const SkMatrix& viewMatrix,
+ const SkRect& rectToDraw,
+ const SkRect& localRect) {
RETURN_IF_ABANDONED
SkDEBUGCODE(this->validate();)
@@ -340,11 +340,11 @@ void GrDrawContext::drawNonAARectToRect(const GrClip& clip,
localRect);
}
-void GrDrawContext::drawNonAARectWithLocalMatrix(const GrClip& clip,
- const GrPaint& paint,
- const SkMatrix& viewMatrix,
- const SkRect& rectToDraw,
- const SkMatrix& localMatrix) {
+void GrDrawContext::fillRectWithLocalMatrix(const GrClip& clip,
+ const GrPaint& paint,
+ const SkMatrix& viewMatrix,
+ const SkRect& rectToDraw,
+ const SkMatrix& localMatrix) {
RETURN_IF_ABANDONED
SkDEBUGCODE(this->validate();)
diff --git a/src/gpu/GrTextureParamsAdjuster.cpp b/src/gpu/GrTextureParamsAdjuster.cpp
index 26fb8a6aa9..579cf96ef3 100644
--- a/src/gpu/GrTextureParamsAdjuster.cpp
+++ b/src/gpu/GrTextureParamsAdjuster.cpp
@@ -114,7 +114,7 @@ static GrTexture* copy_on_gpu(GrTexture* inputTexture, const SkIRect* subset,
}
SkRect dstRect = SkRect::MakeWH(SkIntToScalar(rtDesc.fWidth), SkIntToScalar(rtDesc.fHeight));
- drawContext->drawNonAARectToRect(GrClip::WideOpen(), paint, SkMatrix::I(), dstRect, localRect);
+ drawContext->fillRectToRect(GrClip::WideOpen(), paint, SkMatrix::I(), dstRect, localRect);
return copy.detach();
}
diff --git a/src/gpu/SkGpuDevice.cpp b/src/gpu/SkGpuDevice.cpp
index 21b2b72540..6a317d5edc 100644
--- a/src/gpu/SkGpuDevice.cpp
+++ b/src/gpu/SkGpuDevice.cpp
@@ -1384,7 +1384,7 @@ void SkGpuDevice::internalDrawBitmap(const SkBitmap& bitmap,
// matrices directly on the texture processor.
fDrawContext->drawRect(fClip, grPaint, viewMatrix, dstRect);
} else {
- fDrawContext->drawNonAARectToRect(fClip, grPaint, viewMatrix, dstRect, paintRect);
+ fDrawContext->fillRectToRect(fClip, grPaint, viewMatrix, dstRect, paintRect);
}
}
@@ -1466,17 +1466,17 @@ void SkGpuDevice::drawSprite(const SkDraw& draw, const SkBitmap& bitmap,
return;
}
- fDrawContext->drawNonAARectToRect(fClip,
- grPaint,
- SkMatrix::I(),
- SkRect::MakeXYWH(SkIntToScalar(left),
- SkIntToScalar(top),
- SkIntToScalar(w),
- SkIntToScalar(h)),
- SkRect::MakeXYWH(0,
- 0,
- SK_Scalar1 * w / texture->width(),
- SK_Scalar1 * h / texture->height()));
+ fDrawContext->fillRectToRect(fClip,
+ grPaint,
+ SkMatrix::I(),
+ SkRect::MakeXYWH(SkIntToScalar(left),
+ SkIntToScalar(top),
+ SkIntToScalar(w),
+ SkIntToScalar(h)),
+ SkRect::MakeXYWH(0,
+ 0,
+ SK_Scalar1 * w / texture->width(),
+ SK_Scalar1 * h / texture->height()));
}
void SkGpuDevice::drawBitmapRect(const SkDraw& origDraw, const SkBitmap& bitmap,
@@ -1596,7 +1596,7 @@ void SkGpuDevice::drawDevice(const SkDraw& draw, SkBaseDevice* device,
SkRect srcRect = SkRect::MakeWH(SK_Scalar1 * w / devTex->width(),
SK_Scalar1 * h / devTex->height());
- fDrawContext->drawNonAARectToRect(fClip, grPaint, SkMatrix::I(), dstRect, srcRect);
+ fDrawContext->fillRectToRect(fClip, grPaint, SkMatrix::I(), dstRect, srcRect);
}
bool SkGpuDevice::canHandleImageFilter(const SkImageFilter* filter) {
diff --git a/src/gpu/effects/GrConfigConversionEffect.cpp b/src/gpu/effects/GrConfigConversionEffect.cpp
index 09f0d6cb56..5f51f6a2c7 100644
--- a/src/gpu/effects/GrConfigConversionEffect.cpp
+++ b/src/gpu/effects/GrConfigConversionEffect.cpp
@@ -231,11 +231,11 @@ void GrConfigConversionEffect::TestForPreservingPMConversions(GrContext* context
break;
}
- readDrawContext->drawNonAARectToRect(GrClip::WideOpen(),
- paint1,
- SkMatrix::I(),
- kDstRect,
- kSrcRect);
+ readDrawContext->fillRectToRect(GrClip::WideOpen(),
+ paint1,
+ SkMatrix::I(),
+ kDstRect,
+ kSrcRect);
readTex->readPixels(0, 0, 256, 256, kRGBA_8888_GrPixelConfig, firstRead);
@@ -247,11 +247,11 @@ void GrConfigConversionEffect::TestForPreservingPMConversions(GrContext* context
failed = true;
break;
}
- tempDrawContext->drawNonAARectToRect(GrClip::WideOpen(),
- paint2,
- SkMatrix::I(),
- kDstRect,
- kSrcRect);
+ tempDrawContext->fillRectToRect(GrClip::WideOpen(),
+ paint2,
+ SkMatrix::I(),
+ kDstRect,
+ kSrcRect);
paint3.addColorFragmentProcessor(pmToUPM2);
@@ -261,11 +261,11 @@ void GrConfigConversionEffect::TestForPreservingPMConversions(GrContext* context
break;
}
- readDrawContext->drawNonAARectToRect(GrClip::WideOpen(),
- paint3,
- SkMatrix::I(),
- kDstRect,
- kSrcRect);
+ readDrawContext->fillRectToRect(GrClip::WideOpen(),
+ paint3,
+ SkMatrix::I(),
+ kDstRect,
+ kSrcRect);
readTex->readPixels(0, 0, 256, 256, kRGBA_8888_GrPixelConfig, secondRead);