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

Side by Side Diff: src/effects/gradients/SkTwoPointConicalGradient.h

Issue 18533006: Consider conical shader opaque if it covers entire plane. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | src/effects/gradients/SkTwoPointConicalGradient.cpp » ('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 /* 2 /*
3 * Copyright 2012 Google Inc. 3 * Copyright 2012 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #ifndef SkTwoPointConicalGradient_DEFINED 9 #ifndef SkTwoPointConicalGradient_DEFINED
10 #define SkTwoPointConicalGradient_DEFINED 10 #define SkTwoPointConicalGradient_DEFINED
11 11
12 #include "SkGradientShaderPriv.h" 12 #include "SkGradientShaderPriv.h"
13 13
14 struct TwoPtRadial { 14 struct TwoPtRadial {
15 enum { 15 enum {
16 kDontDrawT = 0x80000000 16 kDontDrawT = 0x80000000
17 }; 17 };
18 18
19 float fCenterX, fCenterY; 19 float fCenterX, fCenterY;
20 float fDCenterX, fDCenterY; 20 float fDCenterX, fDCenterY;
21 float fRadius; 21 float fRadius;
22 float fDRadius; 22 float fDRadius;
23 float fA; 23 float fA;
24 float fRadius2; 24 float fRadius2;
25 float fRDR; 25 float fRDR;
26 bool fConeFillsPlane;
26 27
27 void init(const SkPoint& center0, SkScalar rad0, 28 void init(const SkPoint& center0, SkScalar rad0,
28 const SkPoint& center1, SkScalar rad1); 29 const SkPoint& center1, SkScalar rad1);
29 30
30 // used by setup and nextT 31 // used by setup and nextT
31 float fRelX, fRelY, fIncX, fIncY; 32 float fRelX, fRelY, fIncX, fIncY;
32 float fB, fDB; 33 float fB, fDB;
33 34
34 void setup(SkScalar fx, SkScalar fy, SkScalar dfx, SkScalar dfy); 35 void setup(SkScalar fx, SkScalar fy, SkScalar dfx, SkScalar dfy);
35 SkFixed nextT(); 36 SkFixed nextT();
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 76
76 private: 77 private:
77 typedef SkGradientShaderBase INHERITED; 78 typedef SkGradientShaderBase INHERITED;
78 const SkPoint fCenter1; 79 const SkPoint fCenter1;
79 const SkPoint fCenter2; 80 const SkPoint fCenter2;
80 const SkScalar fRadius1; 81 const SkScalar fRadius1;
81 const SkScalar fRadius2; 82 const SkScalar fRadius2;
82 }; 83 };
83 84
84 #endif 85 #endif
OLDNEW
« no previous file with comments | « no previous file | src/effects/gradients/SkTwoPointConicalGradient.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698