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

Side by Side Diff: include/effects/SkBitmapAlphaThresholdShader.h

Issue 23707019: alpha threshold bitmap shader (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: false->NULL Created 7 years, 3 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/SkShader.h ('k') | include/gpu/GrEffect.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 /*
2 * Copyright 2013 Google Inc.
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
8 #include "SkShader.h"
9 #include "SkBitmap.h"
10 #include "SkRegion.h"
11 #include "SkString.h"
12
13 class SK_API SkBitmapAlphaThresholdShader : public SkShader {
14 public:
15 /**
16 * Creates a shader that samples a bitmap and a region. If the sample is ins ide the region
17 * the alpha of the bitmap color is boosted up to a threshold value. If it i s
18 * outside the region then the bitmap alpha is decreased to the threshold va lue.
19 * The 0,0 point of the region corresponds to the upper left corner of the b itmap
20 * Currently, this only has a GPU implementation, doesn't respect the paint' s bitmap
21 * filter setting, and always uses clamp mode.
22 */
23 static SkShader* Create(const SkBitmap& bitmap, const SkRegion& region, U8CP U threshold);
24 };
OLDNEW
« no previous file with comments | « include/core/SkShader.h ('k') | include/gpu/GrEffect.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698