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

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

Issue 1287263005: change asABitmap to isABitmap on shader (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 4 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
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
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 public: 51 public:
52 TwoPointConicalGradientContext(const SkTwoPointConicalGradient&, const C ontextRec&); 52 TwoPointConicalGradientContext(const SkTwoPointConicalGradient&, const C ontextRec&);
53 ~TwoPointConicalGradientContext() {} 53 ~TwoPointConicalGradientContext() {}
54 54
55 void shadeSpan(int x, int y, SkPMColor dstC[], int count) override; 55 void shadeSpan(int x, int y, SkPMColor dstC[], int count) override;
56 56
57 private: 57 private:
58 typedef SkGradientShaderBase::GradientShaderBaseContext INHERITED; 58 typedef SkGradientShaderBase::GradientShaderBaseContext INHERITED;
59 }; 59 };
60 60
61 BitmapType asABitmap(SkBitmap* bitmap, SkMatrix* matrix, TileMode* xy) const override;
62 SkShader::GradientType asAGradient(GradientInfo* info) const override; 61 SkShader::GradientType asAGradient(GradientInfo* info) const override;
63 bool asFragmentProcessor(GrContext*, const SkPaint&, const SkMatrix&, const SkMatrix*, 62 bool asFragmentProcessor(GrContext*, const SkPaint&, const SkMatrix&, const SkMatrix*,
64 GrColor*, GrProcessorDataManager*, 63 GrColor*, GrProcessorDataManager*,
65 GrFragmentProcessor**) const override; 64 GrFragmentProcessor**) const override;
66 bool isOpaque() const override; 65 bool isOpaque() const override;
67 66
68 SkScalar getCenterX1() const { return SkPoint::Distance(fCenter1, fCenter2); } 67 SkScalar getCenterX1() const { return SkPoint::Distance(fCenter1, fCenter2); }
69 SkScalar getStartRadius() const { return fRadius1; } 68 SkScalar getStartRadius() const { return fRadius1; }
70 SkScalar getDiffRadius() const { return fRadius2 - fRadius1; } 69 SkScalar getDiffRadius() const { return fRadius2 - fRadius1; }
71 const SkPoint& getStartCenter() const { return fCenter1; } 70 const SkPoint& getStartCenter() const { return fCenter1; }
(...skipping 14 matching lines...) Expand all
86 SkPoint fCenter2; 85 SkPoint fCenter2;
87 SkScalar fRadius1; 86 SkScalar fRadius1;
88 SkScalar fRadius2; 87 SkScalar fRadius2;
89 bool fFlippedGrad; 88 bool fFlippedGrad;
90 89
91 friend class SkGradientShader; 90 friend class SkGradientShader;
92 typedef SkGradientShaderBase INHERITED; 91 typedef SkGradientShaderBase INHERITED;
93 }; 92 };
94 93
95 #endif 94 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698