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

Unified Diff: src/images/SkDecodingImageGenerator.cpp

Issue 108663004: make info real in SkPixelRef, and add bitmap::asImageInfo (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 years 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 | « src/image/SkImagePriv.cpp ('k') | tests/PixelRefTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/images/SkDecodingImageGenerator.cpp
diff --git a/src/images/SkDecodingImageGenerator.cpp b/src/images/SkDecodingImageGenerator.cpp
index 2b804441417938042168d4ddce2b65232faceb30..e49f9a4f24350575fa8bbef966569345d5b4a497 100644
--- a/src/images/SkDecodingImageGenerator.cpp
+++ b/src/images/SkDecodingImageGenerator.cpp
@@ -119,11 +119,9 @@ bool SkDecodingImageGenerator::getInfo(SkImageInfo* info) {
if (bitmap.config() == SkBitmap::kNo_Config) {
return false;
}
- if (!SkBitmapToImageInfo(bitmap, &fInfo)) {
+ if (!bitmap.asImageInfo(&fInfo)) {
// We can't use bitmap.config() as is.
- // Must be kARGB_4444_Config.
if (!bitmap.canCopyTo(SkBitmap::kARGB_8888_Config)) {
- // kARGB_4444_Config can copy to kARGB_8888.
SkDEBUGFAIL("!bitmap->canCopyTo(SkBitmap::kARGB_8888_Config)");
return false;
}
« no previous file with comments | « src/image/SkImagePriv.cpp ('k') | tests/PixelRefTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698