| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2016 Google Inc. | 2 * Copyright 2016 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 GrDrawContextPriv_DEFINED | 8 #ifndef GrDrawContextPriv_DEFINED |
| 9 #define GrDrawContextPriv_DEFINED | 9 #define GrDrawContextPriv_DEFINED |
| 10 | 10 |
| 11 #include "GrDrawContext.h" | 11 #include "GrDrawContext.h" |
| 12 #include "GrPathRendering.h" | 12 #include "GrPathRendering.h" |
| 13 | 13 |
| 14 class GrFixedClip; | 14 class GrFixedClip; |
| 15 class GrPath; | 15 class GrPath; |
| 16 struct GrUserStencilSettings; | 16 struct GrUserStencilSettings; |
| 17 | 17 |
| 18 /** Class that adds methods to GrDrawContext that are only intended for use inte
rnal to Skia. | 18 /** Class that adds methods to GrDrawContext that are only intended for use inte
rnal to Skia. |
| 19 This class is purely a privileged window into GrDrawContext. It should never
have additional | 19 This class is purely a privileged window into GrDrawContext. It should never
have additional |
| 20 data members or virtual methods. */ | 20 data members or virtual methods. */ |
| 21 class GrDrawContextPriv { | 21 class GrDrawContextPriv { |
| 22 public: | 22 public: |
| 23 void clearStencilClip(const SkIRect& rect, bool insideClip); | 23 void clearStencilClip(const SkIRect& rect, bool insideClip); |
| 24 | 24 |
| 25 void stencilRect(const GrFixedClip& clip, | 25 void stencilRect(const GrFixedClip& clip, |
| 26 const GrUserStencilSettings* ss, | 26 const GrUserStencilSettings* ss, |
| 27 bool doAA, | 27 bool useHWAA, |
| 28 const SkMatrix& viewMatrix, | 28 const SkMatrix& viewMatrix, |
| 29 const SkRect& rect); | 29 const SkRect& rect); |
| 30 | 30 |
| 31 void stencilPath(const GrPipelineBuilder&, | 31 void stencilPath(const GrPipelineBuilder&, |
| 32 const GrClip&, | 32 const GrClip&, |
| 33 const SkMatrix& viewMatrix, | 33 const SkMatrix& viewMatrix, |
| 34 const GrPath*, | 34 const GrPath*, |
| 35 GrPathRendering::FillType); | 35 GrPathRendering::FillType); |
| 36 | 36 |
| 37 bool drawAndStencilRect(const GrFixedClip&, | 37 bool drawAndStencilRect(const GrFixedClip&, |
| (...skipping 30 matching lines...) Expand all Loading... |
| 68 friend class GrDrawContext; // to construct/copy this type. | 68 friend class GrDrawContext; // to construct/copy this type. |
| 69 }; | 69 }; |
| 70 | 70 |
| 71 inline GrDrawContextPriv GrDrawContext::drawContextPriv() { return GrDrawContext
Priv(this); } | 71 inline GrDrawContextPriv GrDrawContext::drawContextPriv() { return GrDrawContext
Priv(this); } |
| 72 | 72 |
| 73 inline const GrDrawContextPriv GrDrawContext::drawContextPriv () const { | 73 inline const GrDrawContextPriv GrDrawContext::drawContextPriv () const { |
| 74 return GrDrawContextPriv(const_cast<GrDrawContext*>(this)); | 74 return GrDrawContextPriv(const_cast<GrDrawContext*>(this)); |
| 75 } | 75 } |
| 76 | 76 |
| 77 #endif | 77 #endif |
| OLD | NEW |