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: include/core/SkSurface.h

Issue 233943002: remove picture-backed surfaces (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: rebase Created 6 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « include/core/SkCanvas.h ('k') | src/core/SkPictureRecord.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 #ifndef SkSurface_DEFINED 8 #ifndef SkSurface_DEFINED
9 #define SkSurface_DEFINED 9 #define SkSurface_DEFINED
10 10
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 /** 49 /**
50 * Helper version of NewRaster. It creates a SkImageInfo with the 50 * Helper version of NewRaster. It creates a SkImageInfo with the
51 * specified width and height, and populates the rest of info to match 51 * specified width and height, and populates the rest of info to match
52 * pixels in SkPMColor format. 52 * pixels in SkPMColor format.
53 */ 53 */
54 static SkSurface* NewRasterPMColor(int width, int height) { 54 static SkSurface* NewRasterPMColor(int width, int height) {
55 return NewRaster(SkImageInfo::MakeN32Premul(width, height)); 55 return NewRaster(SkImageInfo::MakeN32Premul(width, height));
56 } 56 }
57 57
58 /** 58 /**
59 * Return a new surface whose contents will be recorded into a picture.
60 * When this surface is drawn into another canvas, its contents will be
61 * "replayed" into that canvas.
62 */
63 static SkSurface* NewPicture(int width, int height);
64
65 /**
66 * Return a new surface using the specified render target. 59 * Return a new surface using the specified render target.
67 */ 60 */
68 static SkSurface* NewRenderTargetDirect(GrRenderTarget*); 61 static SkSurface* NewRenderTargetDirect(GrRenderTarget*);
69 62
70 /** 63 /**
71 * Return a new surface whose contents will be drawn to an offscreen 64 * Return a new surface whose contents will be drawn to an offscreen
72 * render target, allocated by the surface. 65 * render target, allocated by the surface.
73 */ 66 */
74 static SkSurface* NewRenderTarget(GrContext*, const SkImageInfo&, int sample Count = 0); 67 static SkSurface* NewRenderTarget(GrContext*, const SkImageInfo&, int sample Count = 0);
75 68
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 178
186 private: 179 private:
187 const int fWidth; 180 const int fWidth;
188 const int fHeight; 181 const int fHeight;
189 uint32_t fGenerationID; 182 uint32_t fGenerationID;
190 183
191 typedef SkRefCnt INHERITED; 184 typedef SkRefCnt INHERITED;
192 }; 185 };
193 186
194 #endif 187 #endif
OLDNEW
« no previous file with comments | « include/core/SkCanvas.h ('k') | src/core/SkPictureRecord.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698