diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/gpu/GrXferProcessor.h | 20 | ||||
-rw-r--r-- | include/gpu/effects/GrCoverageSetOpXP.h | 6 | ||||
-rw-r--r-- | include/gpu/effects/GrPorterDuffXferProcessor.h | 12 |
3 files changed, 14 insertions, 24 deletions
diff --git a/include/gpu/GrXferProcessor.h b/include/gpu/GrXferProcessor.h index 64a0e1ab55..0aa09d8780 100644 --- a/include/gpu/GrXferProcessor.h +++ b/include/gpu/GrXferProcessor.h @@ -19,6 +19,7 @@ class GrShaderCaps; class GrGLSLCaps; class GrGLSLXferProcessor; class GrProcOptInfo; +struct GrPipelineOptimizations; /** * Barriers for blending. When a shader reads the dst directly, an Xfer barrier is sometimes @@ -141,8 +142,7 @@ public: * A caller who calls this function on a XP is required to honor the returned OptFlags * and color values for its draw. */ - OptFlags getOptimizations(const GrProcOptInfo& colorPOI, - const GrProcOptInfo& coveragePOI, + OptFlags getOptimizations(const GrPipelineOptimizations& optimizations, bool doesStencilWrite, GrColor* overrideColor, const GrCaps& caps); @@ -246,8 +246,7 @@ protected: private: void notifyRefCntIsZero() const final {} - virtual OptFlags onGetOptimizations(const GrProcOptInfo& colorPOI, - const GrProcOptInfo& coveragePOI, + virtual OptFlags onGetOptimizations(const GrPipelineOptimizations& optimizations, bool doesStencilWrite, GrColor* overrideColor, const GrCaps& caps) = 0; @@ -311,8 +310,7 @@ GR_MAKE_BITFIELD_OPS(GrXferProcessor::OptFlags); class GrXPFactory : public SkRefCnt { public: typedef GrXferProcessor::DstTexture DstTexture; - GrXferProcessor* createXferProcessor(const GrProcOptInfo& colorPOI, - const GrProcOptInfo& coveragePOI, + GrXferProcessor* createXferProcessor(const GrPipelineOptimizations& optimizations, bool hasMixedSamples, const DstTexture*, const GrCaps& caps) const; @@ -334,8 +332,8 @@ public: virtual void getInvariantBlendedColor(const GrProcOptInfo& colorPOI, InvariantBlendedColor*) const = 0; - bool willNeedDstTexture(const GrCaps& caps, const GrProcOptInfo& colorPOI, - const GrProcOptInfo& coveragePOI, bool hasMixedSamples) const; + bool willNeedDstTexture(const GrCaps& caps, const GrPipelineOptimizations& optimizations, + bool hasMixedSamples) const; bool isEqual(const GrXPFactory& that) const { if (this->classID() != that.classID()) { @@ -363,8 +361,7 @@ protected: private: virtual GrXferProcessor* onCreateXferProcessor(const GrCaps& caps, - const GrProcOptInfo& colorPOI, - const GrProcOptInfo& coveragePOI, + const GrPipelineOptimizations& optimizations, bool hasMixedSamples, const DstTexture*) const = 0; /** @@ -372,8 +369,7 @@ private: * shader. */ virtual bool willReadDstColor(const GrCaps& caps, - const GrProcOptInfo& colorPOI, - const GrProcOptInfo& coveragePOI, + const GrPipelineOptimizations& optimizations, bool hasMixedSamples) const = 0; virtual bool onIsEqual(const GrXPFactory&) const = 0; diff --git a/include/gpu/effects/GrCoverageSetOpXP.h b/include/gpu/effects/GrCoverageSetOpXP.h index a17cf81232..097a890d56 100644 --- a/include/gpu/effects/GrCoverageSetOpXP.h +++ b/include/gpu/effects/GrCoverageSetOpXP.h @@ -30,14 +30,12 @@ private: GrCoverageSetOpXPFactory(SkRegion::Op regionOp, bool invertCoverage); GrXferProcessor* onCreateXferProcessor(const GrCaps& caps, - const GrProcOptInfo& colorPOI, - const GrProcOptInfo& coveragePOI, + const GrPipelineOptimizations& optimizations, bool hasMixedSamples, const DstTexture*) const override; bool willReadDstColor(const GrCaps& /*caps*/, - const GrProcOptInfo& /*colorPOI*/, - const GrProcOptInfo& /*coveragePOI*/, + const GrPipelineOptimizations& /*optimizations*/, bool /*hasMixedSamples*/) const override { return false; } diff --git a/include/gpu/effects/GrPorterDuffXferProcessor.h b/include/gpu/effects/GrPorterDuffXferProcessor.h index 3dc503305f..be014a6b04 100644 --- a/include/gpu/effects/GrPorterDuffXferProcessor.h +++ b/include/gpu/effects/GrPorterDuffXferProcessor.h @@ -22,8 +22,7 @@ public: GrXPFactory::InvariantBlendedColor*) const override; static GrXferProcessor* CreateSrcOverXferProcessor(const GrCaps& caps, - const GrProcOptInfo& colorPOI, - const GrProcOptInfo& coveragePOI, + const GrPipelineOptimizations& optimizations, bool hasMixedSamples, const GrXferProcessor::DstTexture*); @@ -44,22 +43,19 @@ public: } static bool SrcOverWillNeedDstTexture(const GrCaps& caps, - const GrProcOptInfo& colorPOI, - const GrProcOptInfo& coveragePOI, + const GrPipelineOptimizations& optimizations, bool hasMixedSamples); private: GrPorterDuffXPFactory(SkXfermode::Mode); GrXferProcessor* onCreateXferProcessor(const GrCaps& caps, - const GrProcOptInfo& colorPOI, - const GrProcOptInfo& coveragePOI, + const GrPipelineOptimizations& optimizations, bool hasMixedSamples, const DstTexture*) const override; bool willReadDstColor(const GrCaps& caps, - const GrProcOptInfo& colorPOI, - const GrProcOptInfo& coveragePOI, + const GrPipelineOptimizations& optimizations, bool hasMixedSamples) const override; bool onIsEqual(const GrXPFactory& xpfBase) const override { |