Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(142)

Unified Diff: src/core/SkBitmap.cpp

Issue 1576983002: Make SkBitmap::CopyTo respect requested dst color type when bitmap is texture backed. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix size_t warnings Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « include/gpu/SkGrPixelRef.h ('k') | src/core/SkBitmapDevice.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkBitmap.cpp
diff --git a/src/core/SkBitmap.cpp b/src/core/SkBitmap.cpp
index c66a5b2fd5c2495e05386fe3c6d81568c4d87adc..bdf1daafccc25434f6286df55223c5475f665ddd 100644
--- a/src/core/SkBitmap.cpp
+++ b/src/core/SkBitmap.cpp
@@ -828,7 +828,7 @@ bool SkBitmap::copyTo(SkBitmap* dst, SkColorType dstColorType, Allocator* alloc)
SkIRect subset;
subset.setXYWH(fPixelRefOrigin.fX, fPixelRefOrigin.fY,
fInfo.width(), fInfo.height());
- if (fPixelRef->readPixels(&tmpSrc, &subset)) {
+ if (fPixelRef->readPixels(&tmpSrc, dstColorType, &subset)) {
if (fPixelRef->info().alphaType() == kUnpremul_SkAlphaType) {
// FIXME: The only meaningful implementation of readPixels
// (GrPixelRef) assumes premultiplied pixels.
« no previous file with comments | « include/gpu/SkGrPixelRef.h ('k') | src/core/SkBitmapDevice.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698