Chromium Code Reviews| Index: src/gpu/GrClipMaskManager.cpp |
| diff --git a/src/gpu/GrClipMaskManager.cpp b/src/gpu/GrClipMaskManager.cpp |
| index 9b78cdfddaa0a5454fda6f24e5f63ffe7d9ec04b..fa9d189e8c384ac9d6207b68f8f53470e10b151d 100644 |
| --- a/src/gpu/GrClipMaskManager.cpp |
| +++ b/src/gpu/GrClipMaskManager.cpp |
| @@ -317,8 +317,18 @@ bool GrClipMaskManager::setupClipping(const GrPipelineBuilder& pipelineBuilder, |
| } |
| case GrClip::kClipStack_ClipType: { |
| clipSpaceRTIBounds.offset(clip.origin()); |
| + SkIRect clipSpaceReduceQueryBounds; |
| + if (devBounds) { |
|
joshualitt
2015/11/23 17:26:07
When would we not have devbounds?
bsalomon
2015/11/23 17:59:34
Not sure... was planning to investigate that and p
joshualitt
2015/11/23 18:30:50
cool, other than possibly NVPR, everyone would, I
|
| + SkIRect devIBounds = devBounds->roundOut(); |
| + devIBounds.offset(clip.origin()); |
| + if (!clipSpaceReduceQueryBounds.intersect(clipSpaceRTIBounds, devIBounds)) { |
| + return false; |
| + } |
| + } else { |
| + clipSpaceReduceQueryBounds = clipSpaceRTIBounds; |
| + } |
| GrReducedClip::ReduceClipStack(*clip.clipStack(), |
| - clipSpaceRTIBounds, |
| + clipSpaceReduceQueryBounds, |
| &elements, |
| &genID, |
| &initialState, |