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

Unified Diff: src/gpu/GrClip.cpp

Issue 2138083002: skip call to clip::apply when clip is wide open Base URL: https://chromium.googlesource.com/skia.git@llist
Patch Set: rm gcmm Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/GrBlurUtils.cpp ('k') | src/gpu/GrClipMaskManager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrClip.cpp
diff --git a/src/gpu/GrClip.cpp b/src/gpu/GrClip.cpp
index b0577c51222814a0c8f1df815ad9bd0686ca5a2b..0357209ec279857400565a09e3cd0a96926370b0 100644
--- a/src/gpu/GrClip.cpp
+++ b/src/gpu/GrClip.cpp
@@ -6,8 +6,6 @@
*/
#include "GrClip.h"
-
-#include "GrClipMaskManager.h"
#include "GrDrawContext.h"
void GrNoClip::getConservativeBounds(int width, int height, SkIRect* devResult,
@@ -65,33 +63,3 @@ bool GrFixedClip::apply(GrContext*, const GrPipelineBuilder& pipelineBuilder,
out->makeStencil(fHasStencilClip, fDeviceBounds);
return true;
}
-
-bool GrClipStackClip::quickContains(const SkRect& rect) const {
- if (!fStack) {
- return true;
- }
- return fStack->quickContains(rect.makeOffset(SkIntToScalar(fOrigin.x()),
- SkIntToScalar(fOrigin.y())));
-}
-
-void GrClipStackClip::getConservativeBounds(int width, int height, SkIRect* devResult,
- bool* isIntersectionOfRects) const {
- if (!fStack) {
- devResult->setXYWH(0, 0, width, height);
- if (isIntersectionOfRects) {
- *isIntersectionOfRects = true;
- }
- return;
- }
- SkRect devBounds;
- fStack->getConservativeBounds(-fOrigin.x(), -fOrigin.y(), width, height, &devBounds,
- isIntersectionOfRects);
- devBounds.roundOut(devResult);
-}
-
-bool GrClipStackClip::apply(GrContext* context,
- const GrPipelineBuilder& pipelineBuilder, GrDrawContext* drawContext,
- const SkRect* devBounds, GrAppliedClip* out) const {
- return GrClipMaskManager::SetupClipping(context, pipelineBuilder, drawContext,
- *this, devBounds, out);
-}
« no previous file with comments | « src/gpu/GrBlurUtils.cpp ('k') | src/gpu/GrClipMaskManager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698