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

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

Issue 1388113002: Bye bye processor data manager (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: remove files 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 | « include/core/SkComposeShader.h ('k') | include/core/SkShader.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 2011 Google Inc. 2 * Copyright 2011 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 SkImageFilter_DEFINED 8 #ifndef SkImageFilter_DEFINED
9 #define SkImageFilter_DEFINED 9 #define SkImageFilter_DEFINED
10 10
11 #include "../private/SkTemplates.h" 11 #include "../private/SkTemplates.h"
12 #include "SkFilterQuality.h" 12 #include "SkFilterQuality.h"
13 #include "SkFlattenable.h" 13 #include "SkFlattenable.h"
14 #include "SkMatrix.h" 14 #include "SkMatrix.h"
15 #include "SkRect.h" 15 #include "SkRect.h"
16 #include "SkSurfaceProps.h" 16 #include "SkSurfaceProps.h"
17 17
18 class GrFragmentProcessor; 18 class GrFragmentProcessor;
19 class GrProcessorDataManager;
20 class GrTexture; 19 class GrTexture;
21 class SkBaseDevice; 20 class SkBaseDevice;
22 class SkBitmap; 21 class SkBitmap;
23 class SkColorFilter; 22 class SkColorFilter;
24 struct SkIPoint; 23 struct SkIPoint;
25 24
26 /** 25 /**
27 * Base class for image filters. If one is installed in the paint, then 26 * Base class for image filters. If one is installed in the paint, then
28 * all drawing occurs as usual, but it is as if the drawing happened into an 27 * all drawing occurs as usual, but it is as if the drawing happened into an
29 * offscreen (before the xfermode is applied). This offscreen bitmap will 28 * offscreen (before the xfermode is applied). This offscreen bitmap will
(...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after
356 * If effect is non-NULL, a new GrProcessor instance is stored 355 * If effect is non-NULL, a new GrProcessor instance is stored
357 * in it. The caller assumes ownership of the stage, and it is up to the 356 * in it. The caller assumes ownership of the stage, and it is up to the
358 * caller to unref it. 357 * caller to unref it.
359 * 358 *
360 * The effect can assume its vertexCoords space maps 1-to-1 with texels 359 * The effect can assume its vertexCoords space maps 1-to-1 with texels
361 * in the texture. "matrix" is a transformation to apply to filter 360 * in the texture. "matrix" is a transformation to apply to filter
362 * parameters before they are used in the effect. Note that this function 361 * parameters before they are used in the effect. Note that this function
363 * will be called with (NULL, NULL, SkMatrix::I()) to query for support, 362 * will be called with (NULL, NULL, SkMatrix::I()) to query for support,
364 * so returning "true" indicates support for all possible matrices. 363 * so returning "true" indicates support for all possible matrices.
365 */ 364 */
366 virtual bool asFragmentProcessor(GrFragmentProcessor**, GrProcessorDataManag er*, GrTexture*, 365 virtual bool asFragmentProcessor(GrFragmentProcessor**, GrTexture*, const Sk Matrix&,
367 const SkMatrix&, const SkIRect& bounds) con st; 366 const SkIRect& bounds) const;
368 367
369 /** 368 /**
370 * Returns true if this filter can cause transparent black pixels to become 369 * Returns true if this filter can cause transparent black pixels to become
371 * visible (ie., alpha > 0). The default implementation returns false. This 370 * visible (ie., alpha > 0). The default implementation returns false. This
372 * function is non-recursive, i.e., only queries this filter and not its 371 * function is non-recursive, i.e., only queries this filter and not its
373 * inputs. 372 * inputs.
374 */ 373 */
375 virtual bool affectsTransparentBlack() const; 374 virtual bool affectsTransparentBlack() const;
376 375
377 private: 376 private:
(...skipping 15 matching lines...) Expand all
393 */ 392 */
394 #define SK_IMAGEFILTER_UNFLATTEN_COMMON(localVar, expectedCount) \ 393 #define SK_IMAGEFILTER_UNFLATTEN_COMMON(localVar, expectedCount) \
395 Common localVar; \ 394 Common localVar; \
396 do { \ 395 do { \
397 if (!localVar.unflatten(buffer, expectedCount)) { \ 396 if (!localVar.unflatten(buffer, expectedCount)) { \
398 return NULL; \ 397 return NULL; \
399 } \ 398 } \
400 } while (0) 399 } while (0)
401 400
402 #endif 401 #endif
OLDNEW
« no previous file with comments | « include/core/SkComposeShader.h ('k') | include/core/SkShader.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698