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

Side by Side Diff: include/core/SkImage.h

Issue 153583007: Revert "Serialization of SkPictureImageFilter" (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 6 years, 10 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 | « gm/colorfilters.cpp ('k') | include/core/SkPicture.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 #ifndef SkImage_DEFINED 8 #ifndef SkImage_DEFINED
9 #define SkImage_DEFINED 9 #define SkImage_DEFINED
10 10
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 /** 78 /**
79 * If the image has direct access to its pixels (i.e. they are in local 79 * If the image has direct access to its pixels (i.e. they are in local
80 * RAM) return the (const) address of those pixels, and if not null, return 80 * RAM) return the (const) address of those pixels, and if not null, return
81 * the ImageInfo and rowBytes. The returned address is only valid while 81 * the ImageInfo and rowBytes. The returned address is only valid while
82 * the image object is in scope. 82 * the image object is in scope.
83 * 83 *
84 * On failure, returns NULL and the info and rowBytes parameters are 84 * On failure, returns NULL and the info and rowBytes parameters are
85 * ignored. 85 * ignored.
86 */ 86 */
87 const void* peekPixels(SkImageInfo* info, size_t* rowBytes) const; 87 const void* peekPixels(SkImageInfo* info, size_t* rowBytes) const;
88 88
89 /** 89 /**
90 * Encode the image's pixels and return the result as a new SkData, which 90 * Encode the image's pixels and return the result as a new SkData, which
91 * the caller must manage (i.e. call unref() when they are done). 91 * the caller must manage (i.e. call unref() when they are done).
92 * 92 *
93 * If the image type cannot be encoded, or the requested encoder type is 93 * If the image type cannot be encoded, or the requested encoder type is
94 * not supported, this will return NULL. 94 * not supported, this will return NULL.
95 */ 95 */
96 SkData* encode(SkImageEncoder::Type t = SkImageEncoder::kPNG_Type, 96 SkData* encode(SkImageEncoder::Type t = SkImageEncoder::kPNG_Type,
97 int quality = 80) const; 97 int quality = 80) const;
98 98
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 * On failure, false will be returned, and bitmap will unmodified. 133 * On failure, false will be returned, and bitmap will unmodified.
134 */ 134 */
135 // On ice for now: 135 // On ice for now:
136 // - should it respect the particular colortype/alphatype of the src 136 // - should it respect the particular colortype/alphatype of the src
137 // - should it have separate entrypoints for preallocated and not bitmaps? 137 // - should it have separate entrypoints for preallocated and not bitmaps?
138 // - isn't it enough to allow the caller to draw() the image into a canvas? 138 // - isn't it enough to allow the caller to draw() the image into a canvas?
139 bool readPixels(SkBitmap* bitmap, const SkIRect* subset = NULL) const; 139 bool readPixels(SkBitmap* bitmap, const SkIRect* subset = NULL) const;
140 }; 140 };
141 141
142 #endif 142 #endif
OLDNEW
« no previous file with comments | « gm/colorfilters.cpp ('k') | include/core/SkPicture.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698