| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 #include "GrClipMaskManager.h" | 8 #include "GrClipMaskManager.h" |
| 9 #include "GrCaps.h" | 9 #include "GrCaps.h" |
| 10 #include "GrDrawingManager.h" | 10 #include "GrDrawingManager.h" |
| (...skipping 847 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 858 args.fAntiAlias = false; | 858 args.fAntiAlias = false; |
| 859 args.fGammaCorrect = false; | 859 args.fGammaCorrect = false; |
| 860 pr->drawPath(args); | 860 pr->drawPath(args); |
| 861 } else { | 861 } else { |
| 862 GrPathRenderer::StencilPathArgs args; | 862 GrPathRenderer::StencilPathArgs args; |
| 863 args.fTarget = fDrawTarget; | 863 args.fTarget = fDrawTarget; |
| 864 args.fResourceProvider = this->getContext()->resourc
eProvider(); | 864 args.fResourceProvider = this->getContext()->resourc
eProvider(); |
| 865 args.fPipelineBuilder = &pipelineBuilder; | 865 args.fPipelineBuilder = &pipelineBuilder; |
| 866 args.fViewMatrix = &viewMatrix; | 866 args.fViewMatrix = &viewMatrix; |
| 867 args.fPath = &clipPath; | 867 args.fPath = &clipPath; |
| 868 args.fStroke = &stroke; | |
| 869 pr->stencilPath(args); | 868 pr->stencilPath(args); |
| 870 } | 869 } |
| 871 } | 870 } |
| 872 } | 871 } |
| 873 } | 872 } |
| 874 | 873 |
| 875 // now we modify the clip bit by rendering either the clip | 874 // now we modify the clip bit by rendering either the clip |
| 876 // element directly or a bounding rect of the entire clip. | 875 // element directly or a bounding rect of the entire clip. |
| 877 fClipMode = kModifyClip_StencilClipMode; | 876 fClipMode = kModifyClip_StencilClipMode; |
| 878 for (int p = 0; p < passes; ++p) { | 877 for (int p = 0; p < passes; ++p) { |
| (...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1147 | 1146 |
| 1148 //////////////////////////////////////////////////////////////////////////////// | 1147 //////////////////////////////////////////////////////////////////////////////// |
| 1149 | 1148 |
| 1150 void GrClipMaskManager::adjustPathStencilParams(const GrStencilAttachment* stenc
ilAttachment, | 1149 void GrClipMaskManager::adjustPathStencilParams(const GrStencilAttachment* stenc
ilAttachment, |
| 1151 GrStencilSettings* settings) { | 1150 GrStencilSettings* settings) { |
| 1152 if (stencilAttachment) { | 1151 if (stencilAttachment) { |
| 1153 int stencilBits = stencilAttachment->bits(); | 1152 int stencilBits = stencilAttachment->bits(); |
| 1154 this->adjustStencilParams(settings, fClipMode, stencilBits); | 1153 this->adjustStencilParams(settings, fClipMode, stencilBits); |
| 1155 } | 1154 } |
| 1156 } | 1155 } |
| OLD | NEW |