Index: src/gpu/GrClipMaskManager.h |
diff --git a/src/gpu/GrClipMaskManager.h b/src/gpu/GrClipMaskManager.h |
index 98fd3af351c355c5f0116f11790c635c7e8e11ae..a0d742769ca9a4fca81dfaaea8b3c01eb2e53106 100644 |
--- a/src/gpu/GrClipMaskManager.h |
+++ b/src/gpu/GrClipMaskManager.h |
@@ -33,13 +33,23 @@ class SkPath; |
*/ |
class GrAppliedClip : public SkNoncopyable { |
public: |
- GrAppliedClip() {} |
+ GrAppliedClip() : fIsCoCenteredMultisampledDraw(false) {} |
+ |
const GrFragmentProcessor* clipCoverageFragmentProcessor() const { return fClipCoverageFP; } |
const GrScissorState& scissorState() const { return fScissorState; } |
+ /** |
+ * This is used to perform a multisampled clip test when the draw requires MSAA to be disabled. |
+ * It will allow the stencil test to run multisampled by turning on hardware MSAA, but co-locate |
+ * the draw's samples at pixel center so it will still feel like MSAA is disabled. |
+ */ |
+ bool isCoCenteredMultisampledDraw() const { return fIsCoCenteredMultisampledDraw; } |
+ |
private: |
SkAutoTUnref<const GrFragmentProcessor> fClipCoverageFP; |
GrScissorState fScissorState; |
+ bool fIsCoCenteredMultisampledDraw; |
+ |
friend class GrClipMaskManager; |
typedef SkNoncopyable INHERITED; |