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

Unified Diff: samplecode/SampleFilter2.cpp

Issue 1812323003: Remove uses of SkImageDecoder from samplecode (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 9 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 | « samplecode/SampleEmboss.cpp ('k') | samplecode/SampleHairline.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samplecode/SampleFilter2.cpp
diff --git a/samplecode/SampleFilter2.cpp b/samplecode/SampleFilter2.cpp
index 3663f1197142e19a2810fb14c817d15d943af10a..8c93563c409e629b696b3e7e19c4aeb3d54992fd 100644
--- a/samplecode/SampleFilter2.cpp
+++ b/samplecode/SampleFilter2.cpp
@@ -5,12 +5,12 @@
* found in the LICENSE file.
*/
+#include "DecodeFile.h"
#include "SampleCode.h"
#include "SkView.h"
#include "SkCanvas.h"
#include "SkGradientShader.h"
#include "SkGraphics.h"
-#include "SkImageDecoder.h"
#include "SkPath.h"
#include "SkRegion.h"
#include "SkShader.h"
@@ -35,12 +35,10 @@ public:
fBitmaps = new SkBitmap[fBitmapCount];
for (int i = 0; i < fBitmapCount/2; i++) {
- SkImageDecoder::DecodeFile(gNames[i], &fBitmaps[i], kN32_SkColorType,
- SkImageDecoder::kDecodePixels_Mode, nullptr);
+ decode_file(gNames[i], &fBitmaps[i]);
}
for (int i = fBitmapCount/2; i < fBitmapCount; i++) {
- SkImageDecoder::DecodeFile(gNames[i-fBitmapCount/2], &fBitmaps[i], kRGB_565_SkColorType,
- SkImageDecoder::kDecodePixels_Mode, nullptr);
+ decode_file(gNames[i-fBitmapCount/2], &fBitmaps[i], kRGB_565_SkColorType);
}
fCurrIndex = 0;
« no previous file with comments | « samplecode/SampleEmboss.cpp ('k') | samplecode/SampleHairline.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698