aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkImageFilterUtils.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/SkImageFilterUtils.cpp')
-rw-r--r--src/core/SkImageFilterUtils.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/core/SkImageFilterUtils.cpp b/src/core/SkImageFilterUtils.cpp
index 076ef9bb91..92fe67e84c 100644
--- a/src/core/SkImageFilterUtils.cpp
+++ b/src/core/SkImageFilterUtils.cpp
@@ -15,8 +15,14 @@
#include "SkGr.h"
bool SkImageFilterUtils::WrapTexture(GrTexture* texture, int width, int height, SkBitmap* result) {
- SkImageInfo info = SkImageInfo::MakeN32Premul(width, height);
- result->installPixelRef(SkNEW_ARGS(SkGrPixelRef, (info, texture)))->unref();
+ SkImageInfo info = {
+ width,
+ height,
+ kPMColor_SkColorType,
+ kPremul_SkAlphaType,
+ };
+ result->setConfig(info);
+ result->setPixelRef(SkNEW_ARGS(SkGrPixelRef, (info, texture)))->unref();
return true;
}