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

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

Issue 1348583002: Make skpaint->grpaint flow work for composing draws (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: remove unused inheriteds to satisfy clang Created 5 years, 2 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 | « gyp/gpu.gypi ('k') | include/gpu/GrColor.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 2006 The Android Open Source Project 2 * Copyright 2006 The Android Open Source Project
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 SkShader_DEFINED 8 #ifndef SkShader_DEFINED
9 #define SkShader_DEFINED 9 #define SkShader_DEFINED
10 10
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after
308 308
309 /** 309 /**
310 * Returns a GrFragmentProcessor that implements the shader for the GPU bac kend. NULL is 310 * Returns a GrFragmentProcessor that implements the shader for the GPU bac kend. NULL is
311 * returned if there is no GPU implementation. 311 * returned if there is no GPU implementation.
312 * 312 *
313 * The GPU device does not call SkShader::createContext(), instead we pass the view matrix, 313 * The GPU device does not call SkShader::createContext(), instead we pass the view matrix,
314 * local matrix, and filter quality directly. 314 * local matrix, and filter quality directly.
315 * 315 *
316 * The GrContext may be used by the to create textures that are required by the returned 316 * The GrContext may be used by the to create textures that are required by the returned
317 * processor. 317 * processor.
318 *
319 * The returned GrFragmentProcessor should expect an unpremultiplied input color and
320 * produce a premultiplied output.
318 */ 321 */
319 virtual const GrFragmentProcessor* asFragmentProcessor(GrContext*, 322 virtual const GrFragmentProcessor* asFragmentProcessor(GrContext*,
320 const SkMatrix& viewM atrix, 323 const SkMatrix& viewM atrix,
321 const SkMatrix* local Matrix, 324 const SkMatrix* local Matrix,
322 SkFilterQuality, 325 SkFilterQuality,
323 GrProcessorDataManage r*) const; 326 GrProcessorDataManage r*) const;
324 327
325 /** 328 /**
326 * If the shader can represent its "average" luminance in a single color, r eturn true and 329 * If the shader can represent its "average" luminance in a single color, r eturn true and
327 * if color is not NULL, return that color. If it cannot, return false and ignore the color 330 * if color is not NULL, return that color. If it cannot, return false and ignore the color
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
438 SkMatrix fLocalMatrix; 441 SkMatrix fLocalMatrix;
439 442
440 // So the SkLocalMatrixShader can whack fLocalMatrix in its SkReadBuffer con structor. 443 // So the SkLocalMatrixShader can whack fLocalMatrix in its SkReadBuffer con structor.
441 friend class SkLocalMatrixShader; 444 friend class SkLocalMatrixShader;
442 friend class SkBitmapProcShader; // for computeTotalInverse() 445 friend class SkBitmapProcShader; // for computeTotalInverse()
443 446
444 typedef SkFlattenable INHERITED; 447 typedef SkFlattenable INHERITED;
445 }; 448 };
446 449
447 #endif 450 #endif
OLDNEW
« no previous file with comments | « gyp/gpu.gypi ('k') | include/gpu/GrColor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698