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

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

Issue 1086143003: Update more directories under src/ to follow C++11 style rule for {virtual,override}. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: no copyright Created 5 years, 7 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 | « src/codec/SkCodec_libbmp.h ('k') | src/image/SkSurface_Gpu.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 "SkImage_Base.h" 8 #include "SkImage_Base.h"
9 #include "SkBitmap.h" 9 #include "SkBitmap.h"
10 #include "SkCanvas.h" 10 #include "SkCanvas.h"
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 bool onReadPixels(const SkImageInfo&, void*, size_t, int srcX, int srcY) con st override; 59 bool onReadPixels(const SkImageInfo&, void*, size_t, int srcX, int srcY) con st override;
60 const void* onPeekPixels(SkImageInfo*, size_t* /*rowBytes*/) const override; 60 const void* onPeekPixels(SkImageInfo*, size_t* /*rowBytes*/) const override;
61 bool getROPixels(SkBitmap*) const override; 61 bool getROPixels(SkBitmap*) const override;
62 62
63 // exposed for SkSurface_Raster via SkNewImageFromPixelRef 63 // exposed for SkSurface_Raster via SkNewImageFromPixelRef
64 SkImage_Raster(const SkImageInfo&, SkPixelRef*, const SkIPoint& pixelRefOrig in, size_t rowBytes, 64 SkImage_Raster(const SkImageInfo&, SkPixelRef*, const SkIPoint& pixelRefOrig in, size_t rowBytes,
65 const SkSurfaceProps*); 65 const SkSurfaceProps*);
66 66
67 SkPixelRef* getPixelRef() const { return fBitmap.pixelRef(); } 67 SkPixelRef* getPixelRef() const { return fBitmap.pixelRef(); }
68 68
69 virtual SkShader* onNewShader(SkShader::TileMode, 69 SkShader* onNewShader(SkShader::TileMode,
70 SkShader::TileMode, 70 SkShader::TileMode,
71 const SkMatrix* localMatrix) const override; 71 const SkMatrix* localMatrix) const override;
72 72
73 bool isOpaque() const override; 73 bool isOpaque() const override;
74 74
75 SkImage_Raster(const SkBitmap& bm, const SkSurfaceProps* props) 75 SkImage_Raster(const SkBitmap& bm, const SkSurfaceProps* props)
76 : INHERITED(bm.width(), bm.height(), props) 76 : INHERITED(bm.width(), bm.height(), props)
77 , fBitmap(bm) {} 77 , fBitmap(bm) {}
78 78
79 private: 79 private:
80 SkImage_Raster() : INHERITED(0, 0, NULL) {} 80 SkImage_Raster() : INHERITED(0, 0, NULL) {}
81 81
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
229 } 229 }
230 230
231 const SkPixelRef* SkBitmapImageGetPixelRef(const SkImage* image) { 231 const SkPixelRef* SkBitmapImageGetPixelRef(const SkImage* image) {
232 return ((const SkImage_Raster*)image)->getPixelRef(); 232 return ((const SkImage_Raster*)image)->getPixelRef();
233 } 233 }
234 234
235 bool SkImage_Raster::isOpaque() const { 235 bool SkImage_Raster::isOpaque() const {
236 return fBitmap.isOpaque(); 236 return fBitmap.isOpaque();
237 } 237 }
238 238
OLDNEW
« no previous file with comments | « src/codec/SkCodec_libbmp.h ('k') | src/image/SkSurface_Gpu.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698