| 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 #ifndef GrClipStackClip_DEFINED | 7 #ifndef GrClipStackClip_DEFINED |
| 8 #define GrClipStackClip_DEFINED | 8 #define GrClipStackClip_DEFINED |
| 9 | 9 |
| 10 #include "GrClip.h" | 10 #include "GrClip.h" |
| 11 | |
| 12 #include "GrReducedClip.h" | 11 #include "GrReducedClip.h" |
| 13 #include "SkClipStack.h" | 12 #include "SkClipStack.h" |
| 14 | 13 |
| 14 class GrPathRenderer; |
| 15 class GrTexture; |
| 15 class GrTextureProvider; | 16 class GrTextureProvider; |
| 16 class GrPathRenderer; | 17 class GrUniqueKey; |
| 17 | 18 |
| 18 /** | 19 /** |
| 19 * GrClipStackClip can apply a generic SkClipStack to the draw state. It may nee
d to generate an | 20 * GrClipStackClip can apply a generic SkClipStack to the draw state. It may nee
d to generate an |
| 20 * 8-bit alpha clip mask and/or modify the stencil buffer during apply(). | 21 * 8-bit alpha clip mask and/or modify the stencil buffer during apply(). |
| 21 */ | 22 */ |
| 22 class GrClipStackClip final : public GrClip { | 23 class GrClipStackClip final : public GrClip { |
| 23 public: | 24 public: |
| 24 GrClipStackClip(const SkClipStack* stack = nullptr, const SkIPoint* origin =
nullptr) { | 25 GrClipStackClip(const SkClipStack* stack = nullptr, const SkIPoint* origin =
nullptr) { |
| 25 this->reset(stack, origin); | 26 this->reset(stack, origin); |
| 26 } | 27 } |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 70 const GrReducedClip::ElementList& elements); | 71 const GrReducedClip::ElementList& elements); |
| 71 | 72 |
| 72 static GrTexture* CreateCachedMask(int width, int height, const GrUniqueKey&
key, | 73 static GrTexture* CreateCachedMask(int width, int height, const GrUniqueKey&
key, |
| 73 bool renderTarget); | 74 bool renderTarget); |
| 74 | 75 |
| 75 SkIPoint fOrigin; | 76 SkIPoint fOrigin; |
| 76 SkAutoTUnref<const SkClipStack> fStack; | 77 SkAutoTUnref<const SkClipStack> fStack; |
| 77 }; | 78 }; |
| 78 | 79 |
| 79 #endif // GrClipStackClip_DEFINED | 80 #endif // GrClipStackClip_DEFINED |
| OLD | NEW |