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

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

Issue 2176383002: start on apply gamma cleanup (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: Created 4 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 | « src/image/SkImage_Gpu.cpp ('k') | src/image/SkSurface_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 "SkAtomics.h" 8 #include "SkAtomics.h"
9 #include "SkSurface_Base.h" 9 #include "SkSurface_Base.h"
10 #include "SkImagePriv.h" 10 #include "SkImagePriv.h"
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 175
176 sk_sp<SkSurface> SkSurface::makeSurface(const SkImageInfo& info) { 176 sk_sp<SkSurface> SkSurface::makeSurface(const SkImageInfo& info) {
177 return asSB(this)->onNewSurface(info); 177 return asSB(this)->onNewSurface(info);
178 } 178 }
179 179
180 void SkSurface::draw(SkCanvas* canvas, SkScalar x, SkScalar y, 180 void SkSurface::draw(SkCanvas* canvas, SkScalar x, SkScalar y,
181 const SkPaint* paint) { 181 const SkPaint* paint) {
182 return asSB(this)->onDraw(canvas, x, y, paint); 182 return asSB(this)->onDraw(canvas, x, y, paint);
183 } 183 }
184 184
185 bool SkSurface::blitWithGamma(SkImage* image, SkScalar gamma) {
186 return asSB(this)->onBlitWithGamma(image, gamma);
187 }
188
185 bool SkSurface::peekPixels(SkPixmap* pmap) { 189 bool SkSurface::peekPixels(SkPixmap* pmap) {
186 return this->getCanvas()->peekPixels(pmap); 190 return this->getCanvas()->peekPixels(pmap);
187 } 191 }
188 192
189 #ifdef SK_SUPPORT_LEGACY_PEEKPIXELS_PARMS 193 #ifdef SK_SUPPORT_LEGACY_PEEKPIXELS_PARMS
190 const void* SkSurface::peekPixels(SkImageInfo* info, size_t* rowBytes) { 194 const void* SkSurface::peekPixels(SkImageInfo* info, size_t* rowBytes) {
191 SkPixmap pm; 195 SkPixmap pm;
192 if (this->peekPixels(&pm)) { 196 if (this->peekPixels(&pm)) {
193 if (info) { 197 if (info) {
194 *info = pm.info(); 198 *info = pm.info();
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
244 const SkSurfaceProps*) { 248 const SkSurfaceProps*) {
245 return nullptr; 249 return nullptr;
246 } 250 }
247 251
248 sk_sp<SkSurface> MakeFromBackendTextureAsRenderTarget(GrContext*, const GrBacken dTextureDesc&, 252 sk_sp<SkSurface> MakeFromBackendTextureAsRenderTarget(GrContext*, const GrBacken dTextureDesc&,
249 sk_sp<SkColorSpace>, const SkSurfaceProps*) { 253 sk_sp<SkColorSpace>, const SkSurfaceProps*) {
250 return nullptr; 254 return nullptr;
251 } 255 }
252 256
253 #endif 257 #endif
OLDNEW
« no previous file with comments | « src/image/SkImage_Gpu.cpp ('k') | src/image/SkSurface_Base.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698