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

Side by Side Diff: src/image/SkImage.cpp

Issue 345463009: Deleted SkImage::newShaderClamp: not used, not implemented. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Organizing includes of SkImage.h Created 6 years, 5 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 unified diff | Download patch
« no previous file with comments | « include/core/SkImage.h ('k') | src/image/SkImage_Base.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2012 Google Inc. 2 * Copyright 2012 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkBitmap.h" 8 #include "SkBitmap.h"
9 #include "SkCanvas.h" 9 #include "SkCanvas.h"
10 #include "SkImagePriv.h" 10 #include "SkImagePriv.h"
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 // perhaps we could return true + empty-bitmap? 71 // perhaps we could return true + empty-bitmap?
72 return false; 72 return false;
73 } 73 }
74 return as_IB(this)->onReadPixels(bitmap, bounds); 74 return as_IB(this)->onReadPixels(bitmap, bounds);
75 } 75 }
76 76
77 GrTexture* SkImage::getTexture() { 77 GrTexture* SkImage::getTexture() {
78 return as_IB(this)->onGetTexture(); 78 return as_IB(this)->onGetTexture();
79 } 79 }
80 80
81 SkShader* SkImage::newShader(SkShader::TileMode tileX, SkShader::TileMode tileY) const {
82 return as_IB(this)->onNewShader(tileX, tileY);
83 }
84
81 SkData* SkImage::encode(SkImageEncoder::Type type, int quality) const { 85 SkData* SkImage::encode(SkImageEncoder::Type type, int quality) const {
82 SkBitmap bm; 86 SkBitmap bm;
83 if (as_IB(this)->getROPixels(&bm)) { 87 if (as_IB(this)->getROPixels(&bm)) {
84 return SkImageEncoder::EncodeData(bm, type, quality); 88 return SkImageEncoder::EncodeData(bm, type, quality);
85 } 89 }
86 return NULL; 90 return NULL;
87 } 91 }
88 92
89 /////////////////////////////////////////////////////////////////////////////// 93 ///////////////////////////////////////////////////////////////////////////////
90 94
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 131
128 SkCanvas canvas(*bitmap); 132 SkCanvas canvas(*bitmap);
129 133
130 SkPaint paint; 134 SkPaint paint;
131 paint.setXfermodeMode(SkXfermode::kClear_Mode); 135 paint.setXfermodeMode(SkXfermode::kClear_Mode);
132 canvas.drawRect(dstR, paint); 136 canvas.drawRect(dstR, paint);
133 137
134 const_cast<SkImage_Base*>(this)->onDrawRectToRect(&canvas, &srcR, dstR, NULL ); 138 const_cast<SkImage_Base*>(this)->onDrawRectToRect(&canvas, &srcR, dstR, NULL );
135 return true; 139 return true;
136 } 140 }
OLDNEW
« no previous file with comments | « include/core/SkImage.h ('k') | src/image/SkImage_Base.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698