aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkImageFilter.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/SkImageFilter.cpp')
-rw-r--r--src/core/SkImageFilter.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/SkImageFilter.cpp b/src/core/SkImageFilter.cpp
index 18ebcc8e14..49278254c2 100644
--- a/src/core/SkImageFilter.cpp
+++ b/src/core/SkImageFilter.cpp
@@ -283,7 +283,8 @@ sk_sp<SkSpecialImage> SkImageFilter::DrawWithFP(GrContext* context,
sk_sp<GrDrawContext> drawContext(context->newDrawContext(SkBackingFit::kApprox,
bounds.width(), bounds.height(),
- kRGBA_8888_GrPixelConfig));
+ kRGBA_8888_GrPixelConfig,
+ std::move(colorSpace)));
if (!drawContext) {
return nullptr;
}
@@ -294,9 +295,9 @@ sk_sp<SkSpecialImage> SkImageFilter::DrawWithFP(GrContext* context,
GrFixedClip clip(dstIRect);
drawContext->fillRectToRect(clip, paint, SkMatrix::I(), dstRect, srcRect);
- // TODO: Get the colorSpace from the drawContext (once it has one)
return SkSpecialImage::MakeFromGpu(dstIRect, kNeedNewImageUniqueID_SpecialImage,
- drawContext->asTexture(), std::move(colorSpace));
+ drawContext->asTexture(),
+ sk_ref_sp(drawContext->getColorSpace()));
}
#endif