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

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

Issue 741763002: add SkImage::newSurface (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: another warning fix Created 6 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 unified diff | Download patch
« no previous file with comments | « src/image/SkImage_Raster.cpp ('k') | src/image/SkSurface_Gpu.cpp » ('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 "SkSurface_Base.h" 8 #include "SkSurface_Base.h"
9 #include "SkImagePriv.h" 9 #include "SkImagePriv.h"
10 #include "SkCanvas.h" 10 #include "SkCanvas.h"
(...skipping 29 matching lines...) Expand all
40 40
41 SkSurfaceProps::SkSurfaceProps(uint32_t flags, InitType) 41 SkSurfaceProps::SkSurfaceProps(uint32_t flags, InitType)
42 : fFlags(flags) 42 : fFlags(flags)
43 , fPixelGeometry(compute_default_geometry()) 43 , fPixelGeometry(compute_default_geometry())
44 {} 44 {}
45 45
46 SkSurfaceProps::SkSurfaceProps(uint32_t flags, SkPixelGeometry pg) 46 SkSurfaceProps::SkSurfaceProps(uint32_t flags, SkPixelGeometry pg)
47 : fFlags(flags), fPixelGeometry(pg) 47 : fFlags(flags), fPixelGeometry(pg)
48 {} 48 {}
49 49
50 SkSurfaceProps::SkSurfaceProps(const SkSurfaceProps& other)
51 : fFlags(other.fFlags)
52 , fPixelGeometry(other.fPixelGeometry)
53 {}
54
50 /////////////////////////////////////////////////////////////////////////////// 55 ///////////////////////////////////////////////////////////////////////////////
51 56
52 SkSurface_Base::SkSurface_Base(int width, int height, const SkSurfaceProps* prop s) 57 SkSurface_Base::SkSurface_Base(int width, int height, const SkSurfaceProps* prop s)
53 : INHERITED(width, height, props) 58 : INHERITED(width, height, props)
54 { 59 {
55 fCachedCanvas = NULL; 60 fCachedCanvas = NULL;
56 fCachedImage = NULL; 61 fCachedImage = NULL;
57 } 62 }
58 63
59 SkSurface_Base::SkSurface_Base(const SkImageInfo& info, const SkSurfaceProps* pr ops) 64 SkSurface_Base::SkSurface_Base(const SkImageInfo& info, const SkSurfaceProps* pr ops)
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 SkSurface* SkSurface::NewRenderTarget(GrContext*, const SkImageInfo&, int, const SkSurfaceProps*) { 209 SkSurface* SkSurface::NewRenderTarget(GrContext*, const SkImageInfo&, int, const SkSurfaceProps*) {
205 return NULL; 210 return NULL;
206 } 211 }
207 212
208 SkSurface* SkSurface::NewScratchRenderTarget(GrContext*, const SkImageInfo&, int sampleCount, 213 SkSurface* SkSurface::NewScratchRenderTarget(GrContext*, const SkImageInfo&, int sampleCount,
209 const SkSurfaceProps*) { 214 const SkSurfaceProps*) {
210 return NULL; 215 return NULL;
211 } 216 }
212 217
213 #endif 218 #endif
OLDNEW
« no previous file with comments | « src/image/SkImage_Raster.cpp ('k') | src/image/SkSurface_Gpu.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698